Click here to Skip to main content
15,898,036 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralDundas OXMultiComboBox crashes Pin
Bernhard23-Mar-05 20:01
Bernhard23-Mar-05 20:01 
Questionado can not run when WinXP update to sp2? Pin
Lido Paul23-Mar-05 19:54
Lido Paul23-Mar-05 19:54 
QuestionEnd of file? Pin
sacoskun23-Mar-05 19:49
sacoskun23-Mar-05 19:49 
AnswerRe: End of file? Pin
Steve Mayfield23-Mar-05 20:28
Steve Mayfield23-Mar-05 20:28 
GeneralRe: End of file? Pin
sacoskun23-Mar-05 20:38
sacoskun23-Mar-05 20:38 
GeneralRe: End of file? Pin
toxcct23-Mar-05 22:20
toxcct23-Mar-05 22:20 
AnswerRe: End of file? Pin
eli1502197923-Mar-05 22:33
eli1502197923-Mar-05 22:33 
GeneralIt complies and links but .... Pin
brilliant10123-Mar-05 18:11
brilliant10123-Mar-05 18:11 
It is a code from MSDN.
It complies and links but does not executes giving the following error
File:i386\chkesp.c
line:48
The value of ESP was not properly saved across a fuction call.This is usually a result of calling function decleared with one calling convention with a funciton pointer decleared with a different calling convention.

#include windows.h,Setupapi.h>
#include stdio.h

DWORD Err;

HDEVINFO DoDeviceEnum( GUID InterfaceClassGuid)
/*
Routine Description:
Retrieves the device information set that contains that contains
the devices of the specified class.

the devices of the specified class.

Parameters:
InterfaceClassGuid - The interface class GUID.

Return Value:
If the function succeeds, the return value is a handle to the
device information set.

If the function fails, the return value is zero.
*/
{
HDEVINFO DeviceInfoSet;
HDEVINFO NewDeviceInfoSet;

// Create a device information set that will be the container for
// the device interfaces.

DeviceInfoSet = SetupDiCreateDeviceInfoList(NULL, NULL);

if(DeviceInfoSet == INVALID_HANDLE_VALUE) {
Err = GetLastError();
printf( "SetupDiCreateDeviceInfoList failed: %lx.\n", Err );
return 0;
}

// Retrieve the device information set for the interface class.

NewDeviceInfoSet = SetupDiGetClassDevsEx(

&InterfaceClassGuid, // address of guid required

NULL, // no enumerator

NULL, // no parent window handle (might not be a good idea…)

DIGCF_PRESENT | DIGCF_DEVICEINTERFACE, // flags

//DeviceInfoSet, // do not pass this in, not in function prototype

NULL, // NULL implies local machine

NULL // Reserved’ must be null

);

if(NewDeviceInfoSet == INVALID_HANDLE_VALUE)
{
Err = GetLastError();
printf( "SetupDiGetClassDevsEx failed: %lx.\n", Err );
return 0;
}

return NewDeviceInfoSet;
}

int main(int argc, TCHAR* argv[])
{

GUID var;
DoDeviceEnum(var);

return 0;
}
GeneralMFC/GDI Chart Pin
Anonymous23-Mar-05 17:54
Anonymous23-Mar-05 17:54 
GeneralCustom DateTimePicker needed Pin
Mr. Malloc23-Mar-05 17:20
Mr. Malloc23-Mar-05 17:20 
GeneralReading and Loading files Pin
Notsosuperhero23-Mar-05 15:51
Notsosuperhero23-Mar-05 15:51 
GeneralRe: Reading and Loading files Pin
David Crow23-Mar-05 16:43
David Crow23-Mar-05 16:43 
GeneralRe: Reading and Loading files Pin
Christian Graus23-Mar-05 16:45
protectorChristian Graus23-Mar-05 16:45 
GeneralRe: Reading and Loading files Pin
namaskaaram23-Mar-05 19:55
namaskaaram23-Mar-05 19:55 
GeneralMenu Item Check State Pin
Jumpin' Jeff23-Mar-05 15:22
Jumpin' Jeff23-Mar-05 15:22 
GeneralRe: Menu Item Check State Pin
Christian Graus23-Mar-05 15:42
protectorChristian Graus23-Mar-05 15:42 
GeneralRe: Menu Item Check State Pin
Jumpin' Jeff24-Mar-05 2:12
Jumpin' Jeff24-Mar-05 2:12 
GeneralSimple String Input Pin
cockytrumpet23-Mar-05 14:40
susscockytrumpet23-Mar-05 14:40 
GeneralRe: Simple String Input Pin
Christian Graus23-Mar-05 15:47
protectorChristian Graus23-Mar-05 15:47 
GeneralRe: Simple String Input Pin
cockytrumpet23-Mar-05 16:40
susscockytrumpet23-Mar-05 16:40 
GeneralRe: Simple String Input Pin
Christian Graus23-Mar-05 17:21
protectorChristian Graus23-Mar-05 17:21 
GeneralRe: Simple String Input Pin
cockytrumpet23-Mar-05 18:02
susscockytrumpet23-Mar-05 18:02 
GeneralRe: Simple String Input Pin
David Crow23-Mar-05 16:46
David Crow23-Mar-05 16:46 
GeneralKnowing when no data is @ Serial Port Pin
CNewbie23-Mar-05 13:32
CNewbie23-Mar-05 13:32 
GeneralRe: Knowing when no data is @ Serial Port Pin
Mircea Puiu24-Mar-05 5:15
Mircea Puiu24-Mar-05 5:15 

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.