HB_DirSepToOS

HB_DirSepToOS

Convert dir separators in a path to OS standard dir separators

Syntax

      HB_DirSepToOS( <cPath1> ) -> <cPath2>

Argument

<cPath1> : A path with any dir separator in it

Returns

<cPath2> : Converted dir separators to OS standard version of <cPath1>

Description

In paths, “dir separator” is a ‘\’ ( back slash ) for DOS / Windows and a “/” ( slash )for U*nix systems

HB_DirSepToOS() is a function to convert dir separators to OS standard

Example

      LOCAL cDir := 'C:/temp/TestSeps'
      ? HB_DirSepToOS( cDir  )            // C:\temp\TestSeps

Seealso

HB_PathNormalize(), HB_DirSepAdd(), HB_DirSepDel(), TrueName()

HB_DirSepDel

HB_DirSepDel

Delete dir separator at end of a path if exists

Syntax

      HB_DirSepDel( <cPath1> ) -> <cPath2>

Argument

<cPath1> : A path either include or not a dir separator at end

Returns

<cPath2> : Absent dir separator at end version of <cPath1>

Description

In paths, “dir separator” is a ‘\’ ( back slash ) for DOS / Windows and a “/” ( slash )for U*nix systems

HB_DirSepAdd() is a function to delete dir separator to end of a path if it’s exist

Example

      LOCAL cDir := 'C:\temp\TestSeps\'
      ? HB_DirSepDel( cDir )  // C:\temp\TestSeps

Seealso

HB_PathNormalize(), HB_DirSepAdd(), HB_DirSepToOS(), TrueName()

HB_DirSepAdd

HB_DirSepAdd

Add a dir separator to end of a path when its missing

Syntax

      HB_DirSepAdd( <cPath1> ) -> <cPath2>

Argument

<cPath1> : A path either include or not a dir separator at end

Returns

<cPath2> : Added dir separator at end version of <cPath1>

Description

In paths, “dir separator” is a ‘\’ ( back slash ) for DOS / Windows and a “/” ( slash )for U*nix systems

HB_DirSepAdd() is a function to add a dir separator to end of a path when its missing

Example

      LOCAL cDir := 'C:\temp\TestSeps'
      ? HB_DirSepAdd( cDir )          // C:\temp\TestSeps\

Seealso

HB_PathNormalize(), HB_DirSepDel(), HB_DirSepToOS(), TrueName()