Files.SetCurrentDir

Top  Previous  Next

 

Syntax

function Files.SetCurrentDir(NewDir: string): boolean

 

Alternative Names

ibec_SetCurrentDir

 

Description

Sets the current working directory to NewDir and returns TRUE if successful, FALSE otherwise. In case of failure, you can use Shell.GetLastError to see why it failed.

 

See also

Files.GetCurrentDir
Files.CreateDir
Files.RemoveDir

 

Example

execute udsblock 

as

begin

  /* get current working dir */

  curdir = Files.GetCurrentDir();

  GUI.ShowMessage('Current working dir: ' + curdir);

 

  /* set current working dir */ 

  Files.SetCurrentDir('c:\windows\');

 

  /* check current working dir */

  curdir = Files.GetCurrentDir();

  GUI.ShowMessage('Current working dir: ' + curdir);

end