updating oE chdir


include filesys.e 
namespace filesys 
public function chdir(sequence newdir) 

sets a new value for the current directory.


newdir : a sequence, the name for the new working directory.


An integer, 0 on failure, 1 on success.


By setting the current directory, you can refer to files in that directory using just the file name.

The current_dir function will return the name of the current directory.

On Windows the current directory is a public property shared by all the processes running under one shell. On Unix a subprocess can change the current directory for itself, but this will not affect the current directory of its parent process.

Example 1:
if chdir("c:\\euphoria") then 
    f = open("readme.doc", "r") 
    puts(STDERR, "Error: No euphoria directory?\n") 
end if 
See Also:

current_dir, dir

Not Categorized, Please Help


Quick Links

User menu

Not signed in.

Misc Menu