473,379 Members | 1,270 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,379 software developers and data experts.

Check Failure #2 stack around a variable

I have this error around a variable named "value" in a huge code of 54000 lines (DLL)and I cannot debug it

I have in my code more than 100 different declarations of "value" so I want to know how to debug my code!!?

I have done the classic option offered by VS2005 where I reference a client to my application which is a COM server but the client doesn't see the new DLL!!!

please if u have any idea or a beginning of a solution don't hesitate to reply!!!
Mar 11 '08 #1
11 1448
sicarie
4,677 Expert Mod 4TB
I have this error around a variable named "value" in a huge code of 54000 lines (DLL)and I cannot debug it

I have in my code more than 100 different declarations of "value" so I want to know how to debug my code!!?

I have done the classic option offered by VS2005 where I reference a client to my application which is a COM server but the client doesn't see the new DLL!!!

please if u have any idea or a beginning of a solution don't hesitate to reply!!!
Not knowing too much about your code, I usually start with cout statements all around it and leading up to it - including variables I'm not looking at. You can find some pretty interesting things, get a very good idea of what your program is doing by putting cout statements after every line and printing out your variables.
Mar 11 '08 #2
Thx I know very welle what my program is doing but I cannot locate the "value"

I should debug my project

it's the unique solution I thnik

but how !! :(
Mar 11 '08 #3
sicarie
4,677 Expert Mod 4TB
I have in my code more than 100 different declarations of "value" so I want to know how to debug my code!!?
That's your issue right there. Why are you declaring it over 100 times? Why not just declare it once?

PS - compiler errors usually include line numbers. That's the variant it doesn't like.
Mar 11 '08 #4
well it's a mistake but now I want to learn how to DEBUG a COM server

in fact I know how by giving as input the client but this dosen't work for my client
he seeks for the DLL in the same folder
please help!!!
Mar 11 '08 #5
does anyone know how to DEBUG please!!!

I cannot continue with putting messagebox everywhere in my code

any idea or beginning of solution will be helpful
Mar 12 '08 #6
well the problem is resolved, in 2 days this is so much

if i have debuged it, I would resolve it in a half of an hour

thx anyway ;)
Mar 12 '08 #7
weaknessforcats
9,208 Expert Mod 8TB
if i have debuged it, I would resolve it in a half of an hour
Do you not know how to use your debugger?

I assume you have debug builds for the COM server.

You should just be able to step into the code.
Mar 12 '08 #8
what did u mean by DEBUG builds??
Mar 19 '08 #9
weaknessforcats
9,208 Expert Mod 8TB
I mean that in order to use your debugger, there has to be code inside your executable to operate it.

Visual Studio.NET has two type of builds a release build and a debug build.

The debug build has the code required to operate the debugger. So, you make a debug build (usually larger in size because of this debugger code) and use the debugger to debug the program. Then, you make a release build for distribution to your customers.

Therefore, to debug into a DLL you need debug version of that DLL. Usually the debug version is the same name as the release version but has a "d" as the last letter. You need to be sure that all parts of the program are debug builds if you want your debugger to work.

Microsoft even provides a debug build of the operating system for driver writers. Here you need to sign a non-disclosure agreement since the debug build lets you see all of the source code.
Mar 19 '08 #10
thx

but it's not sufficient that I put the DEBUG option only in the general propoerties of my VS2005 project??

I think that it will understand that all the code is Debug build

:(

the problem persist, cuz I have new problems in my code, I need to debug it

could any one help please!!!!
Mar 19 '08 #11
weaknessforcats
9,208 Expert Mod 8TB
In VS2005, go to the configuration manager and set the debug build for your project there.

Then, make sure all of the libraries for linker input are also debug versions.

Then build.

Your debugger should be able to step into the dll code.

I don't know what you mean about setting DEBUG in your projetc general properties sicne there is no place to sset that. The only DEBUG I know about is _DEBUG that is used in the preprocessor settings when making a debug build.
Mar 19 '08 #12

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

Similar topics

0
by: Francesc Guim Bernat | last post by:
Dear colleagues, i'm getting in troubles using one XML library with Visual Studio .NET and Xerces with Xalan. (Xercer 2.4 and Xalan 1.7) When i execute the code i get the next run time error: ...
2
by: news.tkdsoftware.com | last post by:
Aside from comp.compilers, is there any other forum, newsgroup or medium where I can post questions concerning the development of a byte code compiler & virtual stack machine? --
1
by: Chronologic | last post by:
I got this error from my compiler with a little test class I was playing with one afternoon. It's not production code or anything, but it's small and I looked it over pretty carefully and couldn't...
11
by: zhong | last post by:
Error Message: Run-Time Check Failure #0 - The value of ESP was not properly saved across a function call. This is usually a result of calling a function declared with one calling convention...
1
by: Francesc Guim Bernat | last post by:
Dear colleagues, i'm getting in troubles using one XML library with Visual Studio .NET and Xerces with Xalan. When i execute the code i get the next run time error: "Run-Time Check Failure #2...
8
by: Antony | last post by:
compiler£ºVisual Studio.Net 2003 (VC7.1) compile type£ºDebug problem: wanted more information about the "Run-Time Check Failure #n",thanks! Example1: #include "stdafx.h" void malice() {...
0
by: Marty Cruise | last post by:
I successfully deploy my application to 20 domain users. Only one new user is giving me a problem, although he can access all domain resources. When he clicks the installation link on the...
5
by: Alan Little | last post by:
I have affiliates submitting batches of anywhere from 10 to several hundred orders. Each order in the batch must include an order ID, originated by the affiliate, which must be unique across all...
2
momotaro
by: momotaro | last post by:
this is the error message that i kep having: Run-Time Check Failure #3 - The variable 's' is being used without being initialized. and this is the part of the code concerned: void...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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?

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.