Getting the domino data directory and path separator

Hello,

I’ve been working with lotusscript for a while and I can’t seem to find a solution for these two things.

  1. Get (reliably) the domino data directory

    - Right now I use the environment string "Directory", but this depends on the context from which it's being used (i.e. the Directory will be different for a Domino/Notes call).
    
  2. Get the file separator for the Operating System I am using.

Does anyone have a solution to either (or both) of these?

Thanks,

Ryan

Subject: Getting the domino data directory and path separator

@1: I use the following declarations:Declare Sub GetNotesExecDir Lib “nNotes” Alias “OSGetExecutableDirectory” (Byval Directory As String)

Declare Sub GetNotesDataDir Lib “nNotes” Alias “OSGetDataDirectory” (Byval Directory As String)

@2: I seem to remeber that there is a OS function to get this information.

Subject: RE: Getting the domino data directory and path separator

Rob,

Thanks for the information, unfortunately I couldn’t get mine to work. I’m calling this from a Lotus Notes form. I must admit I’ve not used the domino C++ api before, I think I’m calling this correctly, e.g…

Dim dataDir As String

Call GetNotesDataDir(dataDir)

Print("dataDir=" & dataDir)

Call GetNotesExecDir(dataDir)

Print("executeDir=" & dataDir)

… I even tried sending dataDir as “by reference”, e.g…

Declare Sub GetNotesDataDir Lib “nNotes” Alias “OSGetDataDirectory” (Directory As String)

… in all cases, an empty string is returned.

Best Regards,

Ryan