ReadConfigDir

Syntax

ReadConfigDir([in] BSTR ConfigDir,  [in] WORD nPosition)

Description

This method retrieves one directory path of a given PS/nVision Configuration Manager setting (as defined in the Windows Registry). This method differs from the ReadConfig method: it parses out the list of available directories by providing a number representing the position of the directory in the list.

For example, if you had two directories, such as c:\user\nVision\layout and c:\user, and you wanted just the c:\user directory, you would pass in the number two. If the user is looking for the second directory and there is only one, then nothing is retrieved. The list of available configuration settings that can be retrieved is as follows:

  • InstanceDir

  • LayoutDir

  • TemplateDir

  • MacroDir

  • StyleDir

  • DrillDownDir

Example

Dim strDirPath as String
strDirPath = SessionCmd.ReadConfig("LayoutDir", 2)

This retrieves the second directory listed.