|
|
|
Holy cow, man! Assembly language AND Swedish! You rock
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Norwegian.
-David Delaune
|
|
|
|
|
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
That's just happy Swedish
|
|
|
|
|
its urgent...............pls.........
|
|
|
|
|
|
Maximilien wrote: ok.
do we have to work on this??
"Opinions are neither right nor wrong. I cannot change your opinion. I can, however, change what influences your opinion." - David Crow Never mind - my own stupidity is the source of every "problem" - Mixture
cheers,
Alok Gupta
VC Forum Q&A :- I/ IV
Support CRY- Child Relief and You/codeProject$$>
|
|
|
|
|
Emailing your friends directly may get a quicker response.
Isn't there an app wizard in VC6 that makes a text editor application
with a few mouse clicks? A doc-view app (SDI or MDI) with a CEditView
as the view perhaps?
Or did I dream it.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Even more mind-boggling is the existence of the source for wordpad in the visual C++ Samples
Judy
|
|
|
|
|
Brilliant!
I think that's what I was remembering (attempting to, anyway) actually!
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Try using Google.
Anyone who thinks he has a better idea of what's good for people than people do is a swine.
- P.J. O'Rourke
|
|
|
|
|
Hi,
We have an application developed using MFC and works fine on windows xp sp2, recently we wanted to try our application on windows vista. When we run the application on windows vista it crashes, and below is the callstack.
7346382d()
user32.dll!_InternalCallWinProc@20() + 0x23 bytes
user32.dll!_UserCallWinProcCheckWow@32() + 0xb3 bytes
user32.dll!_SendMessageWorker@20() + 0xd5 bytes
user32.dll!_SendMessageA@16() + 0x49 bytes
ourdll.dll!CWnd::SendMessageA(unsigned int message=0x00000010, unsigned int wParam=0x00000000, long lParam=0x00000000) Line 42 + 0x20 bytes C++
and here is the extract from eventlog
Faulting application OURAPP.EXE, version 53.8.0.0, time stamp 0x47626d96, faulting module COMCTL32.dll_unloaded, version 0.0.0.0, time stamp 0x4549bcb0, exception code 0xc0000005, fault offset 0x7346382d, process id 0x7374, application start time 0x01c888ff11ea7ee6.
What I could understand from event log is our application is making a call into COMCTL32.dll after somebody has unloaded from our application space (I may be very well wrong). So then I placed InitCommonControls() call in OURAPP.EXE, now it works fine (it doesnt crash). The application works fine on windows xp sp2 even without this InitCommonControls() call.
Just an additional information we dont use any Common Controls in our application except scroll bars (CScrollBar MFC class). Rest all controls are our own developed and are bundled into ourdll.dll
Could someone please help me in understading the above scenario? Thanks in advance
Cheers,
Suresh
|
|
|
|
|
I would guess you must be using something (maybe indirectly) in the common
controls library that wasn't initialized - like the registration of a window
class.
You should be using InitCommonControlsEx() anyway, even if just for the
ICC_STANDARD_CLASSES control classes.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Mark,
Thanks for your reply. Yeah we may be very well indirectly using some thing in the common controls library, however what I am trying to understand is why this _crash_ only happens on vista? bcoz it works fine on xp sp2 without any InitCommonControls/InitCommonControlsEx call.
Cheers,
Suresh
|
|
|
|
|
sthotakura wrote: why this _crash_ only happens on vista?
It's a different operating system - different version of control libraries, different implementations.
You may have just got lucky on XP...There may be a bug in your code...there may be a bug in Vista.
If you can reproduce the crash consistently, then you should be able to debug it with better detail than just
a stack dump.
There's a lot of unknown possibilities here, but there should be nothing wrong with a call to InitCommonControlsEx(),
especially if you need it
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Thanks Mark,
The application crashes consistently on vista. As you said there is nothing wrong in calling InitCommonControlsEx. I agree with that.
Do you have any idea why comctl32.dll would have been unloaded from my process address space?
Some more information I tried running the application on vista with xp sp2 compatibility mode even then the result was was same.
Any ideas/inputs..?
Cheers,
Suresh
|
|
|
|
|
I have no idea how to decipher your event log entry. What writes that entry?
My best guess reading the entry is that a call to the DLL was made but it was no longer there.
I don't know why it would be unloaded....was it ever loaded?
You should be able to debug this.
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Mark Salsbery wrote: was it ever loaded?
I think YES and NO.
I am able to debug however it stops (causes AV) at that point. While debugging If I look at the Modules Window it shows two entries for comctl32.dll (both are from location SxS folder, but with different versions 5.82 and 6.0.xxxx), however none of these two was loaded at the location mentioned in the eventlog entry.
After placing that InitCommonControls(Ex) call, the Modules Windows shows 3 entries for comctl32.dll (2 from SxS folder and 1 from windows\system32 folder (version 5.82)) and the system32 version was loaded at the location mentioned in the eventlog entry. thats why the application doesnt crash when I place this call.
Any thoghts? Thanks in advance
Cheers,
Suresh
|
|
|
|
|
Loading multiple versions of the comctl32.dll seems a bit suspicious.
Since you have at least one module using version 6 of the common controls,
you may want to follow the steps (for the module(s) using comctl32.dll v.6) in
the section "Using ComCtl32 Version 6 in an Application That Uses Extensions,
Plugins, or a DLL That is Brought into a Process" here:
Using Windows XP Visual Styles[^]
Mark
Mark Salsbery
Microsoft MVP - Visual C++
|
|
|
|
|
Have you looked at Davids thread below about VC 1.5? I wanted to ask him something about flopping around the boat but last time I gave him a fishing post he seemed annoyed.
led mike
|
|
|
|
|
led mike wrote: ...he seemed annoyed.
"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|
|
I guess I misinterpreted your tone in the post I am remembering? I'm glad, I certainly did not intend to annoy you.
So after 4 hours of flopping around in Keith's boat have you figured out his last post yet?
led mike
|
|
|
|
|
led mike wrote: I'm glad, I certainly did not intend to annoy you.
You're fine, as long as you do your own Googling.
led mike wrote: So after 4 hours of flopping around in Keith's boat have you figured out his last post yet?
No, simply because I do not have that compiler handy. I tried it with VS6 and it worked fine, although I did not use C files. Maybe that's the deciding factor...
"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman
"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne
|
|
|
|