On Jan 15, 2007, at 17:47 UTC, Wade Maxfield wrote:

>    How can I choose the application folder during debug as well as the
> application folder during run time, on all platforms?  I'd like to be
able
> to have a couple of relative folders under the root application to
get items
> from in the future, also.

I'm not sure exactly what you're seeing, but in case it helps, here's a
function that I sometimes use in console apps.  Note that I don't know
whether the work-around mentioned in this code is still needed in
2007R1.  Perhaps you can do something similar (checking DebugBuild if
necessary).

Function Folder() As FolderItem
  // Return the folder containing this application, in such a way
  // as to work on both MacOS and Linux.
  
  #if TargetMacOS
    // crawl up out of our package on Mac OS... and work around the bug
in 2006R4:
    Dim f As FolderItem = App.ExecutableFile
    if not f.Directory then f = f.Parent
    f = f.Parent
  #else
    Dim f As FolderItem = GetFolderItem( "" )
  #endif
  
  return f
  
End Function


--
Joe Strout -- [EMAIL PROTECTED]
Verified Express, LLC     "Making the Internet a Better Place"
http://www.verex.com/

_______________________________________________
Unsubscribe or switch delivery mode:
<http://www.realsoftware.com/support/listmanager/>

Search the archives of this list here:
<http://support.realsoftware.com/listarchives/lists.html>

Reply via email to