473,396 Members | 1,777 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

CBitmapButton causes unhandled exception?

I am using VC++ 6, I am trying to add a CBitmapButton to a dialog, I followed the steps from the web page below. I got the bitmap button working but when I exit the dialog box a message appears saying 'Unhandled exception in ModelWizard.exe: 0xC0000005: Access Violation.'
I'm new to programming/MFC and this has me stumped - any help would be greatly app. Thanks

http://www.codersource.net/mfc_bitmap_button.html
Jun 29 '06 #1
5 2428
Banfa
9,065 Expert Mod 8TB
I tried it out and it works as specified for me, perhaps it's something else that you are doing.
Jun 29 '06 #2
I am adding the bitmap button to an existing dialog, the dialog worked fine before the bitmap code now it gives an exception when exiting from the dialog box. Is there something else that needs done? Do you have to destroy the bitmap before exiting the dialog box?
Jun 29 '06 #3
Banfa
9,065 Expert Mod 8TB
I didn't have to do anything, I followed exactly what the link you posted said.

I did not have to destory anything.

I am also using MSVC 6.0 and I added the button to an existing dialogue.

Just because the code appeared to work befor you added this button does not mean that there was/is not an error in it.

Have you tried trapping the exception by running you program in the symbolic debugger.
Jun 29 '06 #4
nope, never heard of a symbolic debugger!?! How do I do that,
Thanks
Jun 29 '06 #5
Banfa
9,065 Expert Mod 8TB
From the menu (actually there are tool bar buttons too)

Build -> Start Debug -> Go

When the exception happens the program will halt at that point and you can examine the call trace and varaibles to see if you can see the problem, which is most likely going to access to an invalid or NULL pointer.
Jun 29 '06 #6

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: yma | last post by:
Hi, I put a .aspx page inside Server.Transfer() within a button. The page was created for testing so it only has button and I did not add code. When I click the button, it gave me an error...
3
by: Jason | last post by:
I'm having a hard time getting a call to HttpWebRequest's GetRequestSteam to work. Each time I try to run it, I get the following error: The underlying connection was closed: Unable to...
11
by: Phil | last post by:
Hi, I've currently setup a local user as described in: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnne...
17
by: OlafMeding | last post by:
Below are 2 files that isolate the problem. Note, both programs hang (stop responding) with hyper-threading turned on (a BIOS setting), but work as expected with hyper-threading turned off. ...
2
by: akameswaran | last post by:
Admittedly this problem causes no actual functional issues aside from an occasional error message when the program exits. The error is: Unhandled exception in thread started by Error in...
8
by: amyl | last post by:
I have an application whose main function is encapsulated in encased in a try/catch block catching Exception. My application has crashed on several occasions with a CLR exception. CLR exception...
5
by: =?Utf-8?B?c3VydHVyeg==?= | last post by:
Hi, I feel like a noob for asking this. When I publish a VB windows application, I want to disable the ability of the the user to continue when there is an unhandled exception. For example,...
3
by: Ken Shimizu | last post by:
I get an error when submitting an .ASPX page in Safari beta, MAC and PC document.getElementbyId(‘FolderBrowser’).submit(); After the server side code has executed without problems I get the...
1
by: Ami | last post by:
We have an application where in SOAP is used as a middle layer to communication between Java Front layer and DCE( Distributed Computing Env) backend layer. We are using Systinet Server for C++ to...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.