: : I have the full path of a file in a CString variable. I want to convert this file path to dos-based path (the 8.3 convention). If anyone can provide me with the code.
: :
: : Thanx in advance
: : Kashif
: :
:
: There's a few ways to do it.
:
: You can use the WIN_32_FIND_DATA structure along with FindFirstFile() etc.. and get the file's name in the classic 8.3 filename format through the "cAlternateFileName" struct member.
:
: Or, you can use the GetShortPathName() function which "obtains the short path form of a specified input path."
:
:
:
:
:
:
: To understand recursive, first you need to understand recursive
:
:
hi there, ofcourse some functions are available to convert you path..I want to give you an alternative..DOS uses the 8.3 format. So every filename of dir-name is truncated to 8 chars..example
c:\program files -> c:\progra~1
c:\mysettings.txt -> c:\mysett~1.txt
if you need to, you can write a procedure for doing this..
Good luck to yaa...
Grz,
Bl@ckBl@de <Feedback: void_void@hotmail.com>