GetExpandedName

  int GetExpandedName(lpszSource, lpszBuffer)    
  LPSTR lpszSource; /* specifies name of compressed file */
  LPSTR lpszBuffer; /* address of buffer for original filename */

The GetExpandedName function retrieves the original name of a compressed file if the files was compressed with the COMPRESS.EXE utility and the -r option was specified.

Parameters

lpszSource

Points to a string that specifies the name of a compressed file.

lpszBuffer

Points to a buffer that receives the name of the compressed file.

Return Value

The return value is TRUE if the function is successful; if an error occurs, the return value is less than zero. The following list identifies possible error return values and their meaning:

Value Meaning

LZERROR_BADINHANDLE The handle identifying the source file, hfSource, was not valid.

Comments

This function retrieves the original filename from the header of the compressed file. If the source file is not compressed, this function copies the filename at which lpszSource points to the buffer at which lpszBuffer points.

If -r option was not set when the file was compressed, the string in the buffer at which lpszBuffer points is invalid.