//=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= // Confidential Trade Secret. // Copyright 1987-2001 Data Access Corporation, Miami FL, USA // All Rights reserved // DataFlex is a registered trademark of Data Access Corporation. // // Module: // RdsGetShortPathName.Pkg // // Purpose: // Defines interface to WinAPI function RdsGetShortPathName // // Author: // Vincent Oorsprong // // Date: // 2001, June, 4th // //=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= #IFNDEF GET_RdsWinAPI_GetShortPathName External_Function WinAPI_RdsGetShortPathName "GetShortPathNameA" Kernel32.Dll Pointer lpszLongPath Pointer lpszShortPath DWord cchBuffer Returns DWord Define MAX_PATH For 260 // 2003-07-29 ------------------------------------ Start Nils G. Svedmyr #If PKG_Version<|CI9 Function RdsGetShortPathName For Desktop String sLongPath Returns String #ELSE Function RdsGetShortPathName Desktop String sLongPath Returns String #ENDIF // 2003-07-29 ------------------------------------ Stop Nils G. Svedmyr String sShortPath Integer iRetval ZeroString MAX_PATH To sShortPath Move (WinAPI_RdsGetShortPathName (AddressOf (sLongPath), AddressOf (sShortPath), MAX_PATH)) To iRetval Function_Return (Cstring (sShortPath)) End_Function // GetShortPathName #ENDIF