How can I find the actual filename of the app that was opened?


The getApplicationName() method requires me to explicitly specify an application name. But I’d like to be able to use the name as it exists on the drive. So if I create an app called A and make a copy called B, I’d like to know whether I opened A or B. I looked at the GetCommandLineParameters method but it seems to only retrieve parameters and doesn’t include the path to the file itself (as one gets from the args sent to main())
How can one get at the parameters that are normally passed into the ‘main()’ function?




Duh. I always think of that stuff for getting to user home, documents, etc. Forgot that one can use it to get current app name as well.
Thanks for the quick answer.