New topic: Location of ProjectFile (resources For Debug Run)
<http://forums.realsoftware.com/viewtopic.php?t=29677> Page 1 of 1 [ 1 post ] Previous topic | Next topic Author Message Karen Post subject: Location of ProjectFile (resources For Debug Run)Posted: Fri Aug 21, 2009 12:30 pm Joined: Fri Sep 30, 2005 8:53 am Posts: 627 n a debug run is there anyway of getting the location (actually a folderItem pointing to) the project File? This would be VERY handy... What i want to do is create an XPlatform method that returns a folderItem pointing to where the App resources folder would be if it exists, without hardcoding the location of the project file. If I COULD get it then I could write Function SpecialFolderResources as Folderitem #if DebugBuild Return ProjectFile.Parent.Child("Resources") #elseIf TargetMacOS Return.AppExecutableFile.Parent.Parent.Child("Resources") #else Return.AppExecutableFile.Parent.Child("Resources") End Function That way, even without needing a IDE script one could debug projects with resources painlessly, though you still would have to move that folder to the build location yourself when you build if you are using resources. Why the IDE does not have (or does it and I missed it?) such a standard mechanism is place (including moving the resources at build) , as the logic appears to be straightforward to me. Alternatively , while I have not used IDE scripts and would rather not depend on them now, looking at it briefly ,it looks like it can get the path to an open project File and set an app property with that value... But is there a way to trigger an IDEScript automatically on opening a project? Thanks, - Karen Top Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending Page 1 of 1 [ 1 post ] -- Over 1500 classes with 29000 functions in one REALbasic plug-in collection. The Monkeybread Software Realbasic Plugin v9.3. http://www.monkeybreadsoftware.de/realbasic/plugins.shtml [email protected]
