1 Reply Latest reply on Apr 22, 2010 7:57 PM by Sean_Wilson

    Trouble opening a folder


      I have a director movie that has the script below to open a folder on the system (view in explorer on windows and finder on a mac) to view its contents. The script works when running in director on windows. I have not tried it on a mac yet. When I publish it, the script just gives an error on windows. Again I have not tried on a mac, but I need it to be cross platform.


      Any help would be appreciated.





      on mouseUp me
      tPath = _movie.path & me.pFolder
        tApp  = getOSDirectory() & "\explorer.exe"
        if ( offset("Windows", _system.environmentProplist.platform) = 0 ) then tApp = "finder.app"
        _player.open(tPath, tApp)






      Thank you

        • 1. Re: Trouble opening a folder
          Sean_Wilson Adobe Community Professional

          If you search this forum, or the 'Basics' forum, you'll find a couple of instances of exactly the same question very recently. Try searching before posting Also, since you're already using Buddy API, you might consider using it for opening folders - again see the recent threads.


          Your current version is probably failing because getOSDirectory() is a function/method of the FileIO xtra and you didn't make it available to your projector.