Click here to Skip to main content
16,015,177 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: USB Information Pin
User 21559718-Aug-08 18:54
User 21559718-Aug-08 18:54 
GeneralRe: USB Information Pin
NewVC++18-Aug-08 19:00
NewVC++18-Aug-08 19:00 
GeneralRe: USB Information Pin
User 21559718-Aug-08 19:47
User 21559718-Aug-08 19:47 
GeneralRe: USB Information Pin
vcprog18-Aug-08 20:09
vcprog18-Aug-08 20:09 
AnswerRe: USB Information Pin
User 21559718-Aug-08 20:27
User 21559718-Aug-08 20:27 
GeneralRe: USB Information Pin
vcprog18-Aug-08 21:02
vcprog18-Aug-08 21:02 
GeneralRe: USB Information Pin
User 21559718-Aug-08 21:58
User 21559718-Aug-08 21:58 
GeneralRe: USB Information Pin
NewVC++19-Aug-08 1:19
NewVC++19-Aug-08 1:19 
i have a problem to add these values in listbox.Problem is that i want to show according data.I mean first i want to show drive name then it's data then other drive name then it's data. Right now it is showing but mixed shoe.Code is here

[code]
DWORD dwDrives=GetLogicalDrives();
if(0==dwDrives)
{
// return FALSE;

}
DWORD dwCount=0;
char chDriveLabel='A';
char szRootpath[5]={0,0,0,0,0};
while(dwDrives !=0)
{
if ((dwDrives & 1) != 0)
{
sprintf(szRootpath,"%c:\\",chDriveLabel);
//removable drive
if(DRIVE_REMOVABLE==GetDriveType(szRootpath))
{
WIN32_FIND_DATA FindFileData;

HANDLE hFind;
//Removable dirve lable

// std::cout <<"Files in " << szRootpath << std::endl;

m_ListCountries.ActivateTopParent();

m_ListCountries.AddString(szRootpath);

AfxMessageBox(szRootpath);


//* represent search all files and directories

szRootpath[3]='*';
hFind=FindFirstFile(szRootpath,&FindFileData);
if (INVALID_HANDLE_VALUE == hFind)
{

// return FALSE;

}
// List all the files in the directory .
do
{
//ignore the sub directories

if (!(FindFileData.dwFileAttributes &

FILE_ATTRIBUTE_DIRECTORY))

{

// std::cout << FindFileData.cFileName << ":";


m_ListCountries.AddString(FindFileData.cFileName);


// m_ListCountries.UpdateData(false);

AfxMessageBox(FindFileData.cFileName);

}
}while (FindNextFile(hFind, &FindFileData) != 0);
FindClose(hFind);

}

}

dwDrives = dwDrives >> 1;//next drive

chDriveLabel++;

}
[/code]

plz help me..
AnswerRe: USB Information Pin
Hamid_RT18-Aug-08 20:22
Hamid_RT18-Aug-08 20:22 
AnswerRe: USB Information Pin
vikas amin19-Aug-08 5:27
vikas amin19-Aug-08 5:27 
QuestionGet value of address from memory(VC++6.0) ? Pin
aa_zz18-Aug-08 17:50
aa_zz18-Aug-08 17:50 
AnswerRe: Get value of address from memory(VC++6.0) ? Pin
Naveen18-Aug-08 17:55
Naveen18-Aug-08 17:55 
JokeRe: Get value of address from memory(VC++6.0) ? Pin
Jijo.Raj18-Aug-08 19:40
Jijo.Raj18-Aug-08 19:40 
GeneralRe: Get value of address from memory(VC++6.0) ? Pin
ThatsAlok19-Aug-08 20:26
ThatsAlok19-Aug-08 20:26 
AnswerRe: Get value of address from memory(VC++6.0) ? Pin
CPallini18-Aug-08 21:55
mveCPallini18-Aug-08 21:55 
AnswerRe: Get value of address from memory(VC++6.0) ? Pin
seet821-Jan-09 17:59
seet821-Jan-09 17:59 
QuestionHow to get the state of Radio button Pin
Preethi_12318-Aug-08 17:38
Preethi_12318-Aug-08 17:38 
AnswerRe: How to get the state of Radio button Pin
Stephen Hewitt18-Aug-08 17:49
Stephen Hewitt18-Aug-08 17:49 
AnswerRe: How to get the state of Radio button Pin
dybs18-Aug-08 17:54
dybs18-Aug-08 17:54 
GeneralRe: How to get the state of Radio button Pin
Stephen Hewitt18-Aug-08 18:02
Stephen Hewitt18-Aug-08 18:02 
GeneralRe: How to get the state of Radio button Pin
dybs18-Aug-08 19:34
dybs18-Aug-08 19:34 
QuestionProblem with Edit box Pin
sunny_vc18-Aug-08 16:54
sunny_vc18-Aug-08 16:54 
AnswerRe: Problem with Edit box Pin
Nibu babu thomas18-Aug-08 18:38
Nibu babu thomas18-Aug-08 18:38 
AnswerRe: Problem with Edit box Pin
David Crow19-Aug-08 3:44
David Crow19-Aug-08 3:44 
QuestionWhat is the include for CText Pin
simon alec smith18-Aug-08 9:42
simon alec smith18-Aug-08 9:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.