getrelativefilename

given an absolute directory and an absolute filename, returns a relative file name

Calling Sequence

rel_file = getrelativefilename(abs_dir,abs_file)

Arguments

abs_dir a character string:
 an absolute directory.

: :abs_file a character string: an absolute filename. : :rel_file a character string : relative filename. :

Description

Given an absolute directory abs_dir and an absolute filename abs_file, getrelativefilename returns a relative file name rel_file.

For example, if the current directory is C:scilabbin and the filename C:scilabmoduleshelptoolsreadme.txt is given, getrelativefilename will return ..moduleshelptoolsreadme.txt.

Examples

getrelativefilename(pwd(), SCI+'/COPYING')
getrelativefilename(TMPDIR, SCI+'/COPYING')
getrelativefilename(SCI+'/bin', SCI+'/COPYING')
getrelativefilename(pwd(), SCI+'/ACKNOLEDGMENTS')
getrelativefilename(TMPDIR, SCI+'/ACKNOLEDGMENTS')
getrelativefilename(SCI+'/bin', SCI+'/ACKNOLEDGMENTS')

See Also

Table Of Contents

This Page