|
The pre-compiled header is missing. Rebuild everything and you should be ok.
|
|
|
|
|
I get this error on "Rebuild All"
- Nitron
"Those that say a task is impossible shouldn't interrupt the ones who are doing it." - Chinese Proverb
|
|
|
|
|
All your source files are setup to use the PCH file but non are set to actually build it.
Tim Smith
I'm going to patent thought. I have yet to see any prior art.
|
|
|
|
|
I have gotten this from time to time. Eventually it aggrivated me to an extent that I just changed my project settings.
In Pre-compiled headers, set it to "Automatic" (for all configurations.) Then you will never see this error again.
"When a man sits with a pretty girl for an hour, it seems like a minute. But let him sit on a hot stove for a minute and it's longer than any hour. That's relativity." - Albert Einstein
|
|
|
|
|
How can I get Hardware Information via DMI ? Are there any examples in which case I can use DMI with Visual C++ ?
thnx,
Sendel
|
|
|
|
|
Use WMI to get what you're looking for. DMI is in a protected low-memory area of the bios and Windows won't let you get at it without writing a device driver to the best of my knowledge.
|
|
|
|
|
I have no idea why. When I create a new SDI or MDI MFC-Application, compile the wizard generated code, open the aboutbox -> crash
It also crashes even if I want to display a simple messagebox.
Would be nice if someone could help me.
|
|
|
|
|
It's hard to help debug without examples of code.
Kuphryn
|
|
|
|
|
It even crashes with the wizard-generated code.
New project. SDI and disabled ActiveX the rest as default. Compile and try to open the aboutbox
I know that he crashs at:
CAboutDlg aboutdlg;
aboutdlb.doModal(); <-- crashes in this function.
I also checked some "learn c++"-example apps and they also crashed when I opened the aboutbox.
I don't understand why it works in dialogapps and not in SDI.
|
|
|
|
|
Try to debug it and check what the debugger stops at when the crash happens. VC6? Have you installed the service packs? What system do you run?
Regards,
BB
|
|
|
|
|
I'm running WinXP and VC.Net
The closest point I could trace the crash is in dlgcore.cpp
in the function CreateDlgIndirect(LPCDLGTEMPLATE lpDialogTemplate,CWnd* pParentWnd, HINSTANCE hInst)
at the end of the TRY-part
// create modeless dialog
AfxHookWindowCreate(this);
hWnd = ::CreateDialogIndirect(hInst, lpDialogTemplate, <- here it crashes
pParentWnd->GetSafeHwnd(), AfxDlgProc);
I don't understand why this function works when the mainwindow opens but crashes when another window is openen like the aboutbox, a dialogbox or just a simple messagebox.
Is there another way to open dialogboxes? Or am I the only one with this problem?
|
|
|
|
|
1. Is hInst an appropriate module handle?
2. Is lpDialogTemplate valid?
3. Is parent non-NULL and also valid? (!!!)
If so, send me a sample project pls.
mail@BartoszBien.com
Regards,
BB
|
|
|
|
|
Im working on a dialog based application. I need use of the arrows keys, but when I add handlers for the keydown events, they are already being handled, so when I use the arrow keys, it only changes the focus to the next button in hte dialog. How do I overide the use of the arrow keys?
Dean and Roy Suck...
Kevin Shaffer
Student of Computer Science
University of Kansas
kshaff03@msn.com
|
|
|
|
|
|
Override CYourDialog::PreTranslateMessage .
Regards,
BB
|
|
|
|
|
Is there a way to open the WinSta0 (default window station) of a specific Terminal Services session?
Specifically, my problem revolves around drawing a System Tray icon in the correct tray whenever a user switches sessions (i.e. in WinXP using Fast User Switching). If I just use the currently open window station, the tray icon does not get drawn. Since there is no way to tell the Shell_NotifyIcon which session to draw in, I need to open the window station of the correct session and have my process use that station instead.
Any ideas?
thanks!
|
|
|
|
|
My brain is hurting on this one....
When I make a call to WTSQuerySessionInformation to retrieve the current WindowStation name, how do i declare the LPTSTR variable (ppBuffer) that I need to pass?
I've tried a few different ways, but I either get a GPF, garbage, or nothing being returned.
Does anyone have a sample of this call in action?
thanks
|
|
|
|
|
LPTSTR pBuffer;
WTSQuerySessionInformation(..., &pBuffer, ....);
//... Do your stuff
WTSFreeMemory(pBuffer);
|
|
|
|
|
Excellent! That worked perfectly.
Thanks again
|
|
|
|
|
I am trying to let a media player control play back a movie continuously unless stopped by user, however, after 23 minutes, the application got a "stack overflow" error.
Anybody can help on this by giving me some ideas on this and related issues? - "stack overflow" and how the MFC/C++ deal with this?
Thanks
JW
DJ
|
|
|
|
|
|
NT/2k/XP have a 1MB stack limit, though I believe it can be extended. However, I can't conceive of a reason to do so. The only reason you would hit this limit are doing huge allocations on the stack with alloca() or other means or you have a recursive function. I'll place bets on the latter.
Note, this is an SEH exception (vs. C++ exception) which you can catch and handle to help direct you to the offending code.
|
|
|
|
|
I will be trying to catch and handle the exception.
But, for this case, it is not anything codes wrong, I just wanted to use a Media Player Control to play back a movie continuously, or for ever unless stopped. The applicaiton could run about 22 munitues before the expection popped up.
For applying Windows Controls, seems I have no way to find out how the Control deal with the Stack. Any more suggestions?
THanks
JW
DJ
|
|
|
|
|
I will be trying to catch and handle the exception.
But, for this case, it is not anything codes wrong, I did not allocate huge blocks on the Stack, nor using recursive functions.
I just wanted to use a Media Player Control to play back a movie continuously, or for ever unless stopped. The applicaiton could run about 22 munitues before the expection popped up.
For applying Windows Controls, seems I have no way to find out how the Control deal with the Stack. Any more suggestions?
THanks
JW
DJ
|
|
|
|
|
The only reference I could find on the web is that the older control has an unchecked strcpy in it which can overright the stack. This is a third way to overflow the stack: create an artificial recursive function, but it's rare since it usually throws other types of exceptions (though I've had it happen to me.)
Could their also be a callback not being handled/exited correctly (it's not these controls have the greatest of documentation for their esoteric aspects)?
|
|
|
|