I have found it in winbase.h
#define INVALID_SET_FILE_POINTER ((DWORD)-1)
but only in sdk downloaded from Microsoft. This define does not exist (on my computer) in both VC6.0 and VC7.0 include/src folders.
My hope is that the object gets destroyed when the function goes out of scope. Is thsi true or am I setting myself up for a massive memory leak?
I seem to remember something about this _ConnectionPtr being a smart pointer but maybe thats just wishful thinking. DOes anyone have any experience with this? Your suggestions are welcome. I'd not have done it this way but no other way seemed to work. I tried for two days and finally went this route.
If I createInstance only once somewhere in an initialising event, and then in my function try to do m_pConn.Open, it throws an exception, but the errors collection is empty, plus its not a com error. SO at my wits end I tried this and it worked> technically my first try should work, but it would open the conn once successfully, then even if I closed it, it wouldnt open it a second time!
I have to be 100% sure about a potential leak here though. Makes me nervous.
Thanks for responding,
Im about to start a major GU Idevelopment and I was hoping that you all could share some suggestions for Third-Party Tools.
Drop A link in this thread and tell me what toolkits you have used for things like:
Secure Communications (SSL / Certificates?)
Cross-Platform GUI Development (GUI Toolkits like Qt)
Data Visualization (Graphs, Trending)(SPecifically Trending Graphs (Like Task Manager -> CPU Usage)
Look-and-Feel Widgets (XP Style)(Ulitmate Toolbox)
It would be nice to have a list of all the tools out there. Im Wondering what everyone uses.
Fuel Cell Technologies Inc.
This question is related to TCP socket server. Suppose client and server are running on different machines of the network. What happens if the client machine improperly shutdown or its network cable is removed. Is there any way that server determine that the client socket is no longer valid ????
Can someone help me to get icons associated with a tree ctrl, please?
I have a tree control displaying a project/sub-project file structure, and I would like to add an icon to each leaf based on a certain condition.
The icons are resources, and not to be associated with other apps or anything.
thanks for your help!
I just tried to run some code i got directly from MSDN, non-modified, but at the acmFormatChoose line it gives me a message about a "breakpoint called from code at 0xXXXXXX", anyone have a clue what's wrong?
// Initialize the ACMFORMATCHOOSE members.
memset(&afc, 0, sizeof(afc));
afc.cbStruct = sizeof(afc);
afc.fdwStyle = 0L; // no special style flags
afc.hwndOwner = ghWnd; // hwnd of parent window
afc.pwfx = &wfxSelection; // wfx to receive selection
afc.cbwfx = sizeof(wfxSelection);
afc.pszTitle = TEXT("16 Bit PCM Selection");
// Request that all 16-bit PCM formats be displayed for the user // to select from.
memset(&wfxEnum, 0, sizeof(wfxEnum));
wfxEnum.wFormatTag = WAVE_FORMAT_PCM;
wfxEnum.wBitsPerSample = 16;
afc.fdwEnum = ACM_FORMATENUMF_WFORMATTAG | ACM_FORMATENUMF_WBITSPERSAMPLE;
afc.pwfxEnum = &wfxEnum;
mmr = acmFormatChoose(&afc);
if ((MMSYSERR_NOERROR != mmr) && (ACMERR_CANCELED != mmr))
// There was a fatal error in bringing up the list // dialog box (probably invalid input parameters).