Search code examples
lotus-noteslotus-domino

How to capture the Notes Data directory specified in notes.ini?


I need to get the value for the Notes data directory. I need it for a scheduled agent I am going to run. The program directory and data directory are on separate drives.

I thought the following code would work but I am not getting a return value.

String console = session.sendConsoleCommand(servername, "show config Directory");

//Code runs but the following line does not display anything

System.out.println(" Here is console value: " + console);

There are not any permission or other errors. What am I missing?

V/R,

Kev


Solution

  • Why use this obscure construct? Do you need the directory of ANOTHER server?

    If you need it from the server where the agent runs then just use

    String directory = session.getEnvironmentString("Directory", true)