|
of_getaltfilename
|
|
Full name
|
pfc_n_cst_filesrvsol2.of_getaltfilename
|
Access
|
public
|
Extend of
|
string
|
Return value
|
string
|
Prototype
|
public function string of_getaltfilename(string)
|
Name
|
Datatype
|
lstr_FindData
|
os_finddata
|
lul_handle
|
ulong
|
public function string of_getaltfilename (string as_longfilename);//////////////////////////////////////////////////////////////////////////////
// Public Function: of_GetAltFilename
// Arguments: as_LongFileName The long file name for which the alternate (short)
// file name is desired; an absolute path may be
// specified or it will be relative to the current working directory.
// Returns: String The alternate file name (without the path).
// Returns an empty string if an error occurrs.
// Description: Get the alternate file name name for a Win32 long file.
//////////////////////////////////////////////////////////////////////////////
// Rev. History: Version
// 5.0.02 Initial version
//////////////////////////////////////////////////////////////////////////////
// Copyright © 1996-1999 Sybase, Inc. and its subsidiaries. All rights reserved. Any distribution of the
// PowerBuilder Foundation Classes (PFC) source code by other than Sybase, Inc. and its subsidiaries is prohibited.
//////////////////////////////////////////////////////////////////////////////
ulong lul_handle
os_finddata lstr_FindData
// Find the long file name
lul_handle = FindFirstFileA(as_LongFileName, lstr_FindData)
If lul_handle <= 0 Then Return ""
FindClose(lul_handle)
Return lstr_FindData.ch_alternatefilename
end function