I have something in a ListBox withe a file thing in it where you can nav. through your files. How do I show the full name instead of just DOS name?
I have something in a ListBox withe a file thing in it where you can nav. through your files. How do I show the full name instead of just DOS name?
Website(s): http://www16.brinkster.com/trifaze/
E-mail: [email protected]
---------------------------------
C++ Environment: MSVC++ 6.0; Dev-C++ 4.0/4.1
DirectX Version: 9.0b
DX SDK: DirectX 8.1 SDK
How are you putting the file names in the listbox? Either sending a LB_DIR message or using the DlgDirList() function will result in the full name being displayed.
zen
I am using LB_DIR. When it's in the LB it shows up as something like this:
(example)
progr~1.exe
How do I show:
"program.exe"?
Website(s): http://www16.brinkster.com/trifaze/
E-mail: [email protected]
---------------------------------
C++ Environment: MSVC++ 6.0; Dev-C++ 4.0/4.1
DirectX Version: 9.0b
DX SDK: DirectX 8.1 SDK
not sure what header this is in...try stdlib.h...here's the list of headers I have at the top of the program I have this in
#include <windows.h>
#include <stdio.h>
#include "resource.h"
#include "resrc1.h"
#include <mmsystem.h>
#include <process.h>
#include <stdio.h>
#include <conio.h>
#include <io.h>
#include <string.h>
#include <stdlib.h>
that help you any?Code:char pathname[255]={0}; struct _finddata_t fileinfo; long findhandle; GetDlgItemText(hwnd, IDC_FOLDER, pathname, 255); strcat(pathname,"*.mp3"); findhandle = _findfirst(pathname,&fileinfo); if (findhandle==-1) { MessageBox(NULL, "Directory Not Found", "Error", MB_OK); return FALSE; } SendMessage(hwndList, LB_ADDSTRING, 0, (LPARAM)fileinfo.name); while(_findnext(findhandle,&fileinfo)==0) { SendMessage(hwndList, LB_ADDSTRING, 0, (LPARAM)fileinfo.name); }
There is no call to
_findclose()
to terminate the function call
"Man alone suffers so excruciatingly in the world that he was compelled to invent laughter."
Friedrich Nietzsche
"I spent a lot of my money on booze, birds and fast cars......the rest I squandered."
George Best
"If you are going through hell....keep going."
Winston Churchill