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

need urgent help to deebug a process

Hello!

We have a C#.ASP.NET web application that runs on a IIS 6. The application
contains actually several asp pages but there is no GUI.
The application receive an xml file that is processed.
There is also an MFC dll that is called from this asp application to make a
syntax check on quite many commands.
You don't have to know what a command is.

The problem that we get is the following when the asp pages calls the MFC
dll it will run into protected memory error.
The IIS runs on a windows server 2003.
We have also added some rows in the MFC dll to write to a file about where
in the
dll it is executing and also write some value for different variables.

We have also build the dll in debug mode and copied it to the windows server
2003 and it will result in the same protected memory error.

Another thing that is of interest is that if we run the built-in application
server in Visual Studio which exist by default we never get any kind of
error. Note I don't mean IIS here.

This is strange because when we run the built-in application server the asp
will call the MFC dll but when we run it in this way we never get any
kind of problem.

We have also copied and change the asp pages to be runable in a windows form
application which will call the
MFC dll and here we never get any kind of problem either.

Another very strange thing is that when we add statements to write to a file
it might cause the application to work.

So if we have for example 10 statement to write to a file in
the MFC DLL we get protected memory but if we then
add some more statement to write to a file it might cause the application to
work
and NOT cause any protected memeory.

I hope to get some information about this strange problem that we have.
For example I wonder about the row that cause the crash.
As I said before it sounds strange that there should be an error on that row
when it works when we run and call the MFC dll in two different local modes
which are.
1. Use Visual Studio and the built-in application server
2. Use Windows forms that call the MFC dll

I have now installed the local IIS.

What I want to do is debug the process that is calling the MFC DLL is that
possible?
Can somebody explain the steps that need to be done if I want to debug the
MFC dll
from within VS.
//Tony
Nov 4 '08 #1
3 1345


"Tony Johansson" <t.*********@logica.comwrote in message
news:eZ**************@TK2MSFTNGP03.phx.gbl...
Hello!

We have a C#.ASP.NET web application that runs on a IIS 6. The application
contains actually several asp pages but there is no GUI.
The application receive an xml file that is processed.
There is also an MFC dll that is called from this asp application to make
a
syntax check on quite many commands.
You don't have to know what a command is.

The problem that we get is the following when the asp pages calls the MFC
dll it will run into protected memory error.
The IIS runs on a windows server 2003.
We have also added some rows in the MFC dll to write to a file about where
in the
dll it is executing and also write some value for different variables.

We have also build the dll in debug mode and copied it to the windows
server
2003 and it will result in the same protected memory error.

Another thing that is of interest is that if we run the built-in
application
server in Visual Studio which exist by default we never get any kind of
error. Note I don't mean IIS here.

This is strange because when we run the built-in application server the
asp
will call the MFC dll but when we run it in this way we never get any
kind of problem.

We have also copied and change the asp pages to be runable in a windows
form
application which will call the
MFC dll and here we never get any kind of problem either.

Another very strange thing is that when we add statements to write to a
file
it might cause the application to work.

So if we have for example 10 statement to write to a file in
the MFC DLL we get protected memory but if we then
add some more statement to write to a file it might cause the application
to work
and NOT cause any protected memeory.

I hope to get some information about this strange problem that we have.
For example I wonder about the row that cause the crash.
As I said before it sounds strange that there should be an error on that
row
when it works when we run and call the MFC dll in two different local
modes
which are.
1. Use Visual Studio and the built-in application server
2. Use Windows forms that call the MFC dll

I have now installed the local IIS.

What I want to do is debug the process that is calling the MFC DLL is that
possible?
Can somebody explain the steps that need to be done if I want to debug the
MFC dll
from within VS.
Not sure what this has to do with C# however...

You've got the MFC project on your local machine and the website also so.
Build a debug version of the project and have the web app use that dll from
its build location. In VS with the project loaded attach native debugging
to the w3wp.exe process that represents your web app. Now you can set break
points in your MFC code to trace through what is happening.

--
Anthony Jones - MVP ASP/ASP.NET

Nov 4 '08 #2
Hello!

So you mean I first start the asp.net web application from my local IIS
which is from within VS.
I just wonder at what point do I attach to the process w3wp you meantioned
in your main

//Tony
"Anthony Jones" <An***********@yadayadayada.comwrote in message
news:uv**************@TK2MSFTNGP04.phx.gbl...
>

"Tony Johansson" <t.*********@logica.comwrote in message
news:eZ**************@TK2MSFTNGP03.phx.gbl...
>Hello!

We have a C#.ASP.NET web application that runs on a IIS 6. The
application
contains actually several asp pages but there is no GUI.
The application receive an xml file that is processed.
There is also an MFC dll that is called from this asp application to make
a
syntax check on quite many commands.
You don't have to know what a command is.

The problem that we get is the following when the asp pages calls the MFC
dll it will run into protected memory error.
The IIS runs on a windows server 2003.
We have also added some rows in the MFC dll to write to a file about
where in the
dll it is executing and also write some value for different variables.

We have also build the dll in debug mode and copied it to the windows
server
2003 and it will result in the same protected memory error.

Another thing that is of interest is that if we run the built-in
application
server in Visual Studio which exist by default we never get any kind of
error. Note I don't mean IIS here.

This is strange because when we run the built-in application server the
asp
will call the MFC dll but when we run it in this way we never get any
kind of problem.

We have also copied and change the asp pages to be runable in a windows
form
application which will call the
MFC dll and here we never get any kind of problem either.

Another very strange thing is that when we add statements to write to a
file
it might cause the application to work.

So if we have for example 10 statement to write to a file in
the MFC DLL we get protected memory but if we then
add some more statement to write to a file it might cause the application
to work
and NOT cause any protected memeory.

I hope to get some information about this strange problem that we have.
For example I wonder about the row that cause the crash.
As I said before it sounds strange that there should be an error on that
row
when it works when we run and call the MFC dll in two different local
modes
which are.
1. Use Visual Studio and the built-in application server
2. Use Windows forms that call the MFC dll

I have now installed the local IIS.

What I want to do is debug the process that is calling the MFC DLL is
that possible?
Can somebody explain the steps that need to be done if I want to debug
the MFC dll
from within VS.

Not sure what this has to do with C# however...

You've got the MFC project on your local machine and the website also so.
Build a debug version of the project and have the web app use that dll
from its build location. In VS with the project loaded attach native
debugging to the w3wp.exe process that represents your web app. Now you
can set break points in your MFC code to trace through what is happening.

--
Anthony Jones - MVP ASP/ASP.NET
Nov 4 '08 #3
"Tony Johansson" <t.*********@logica.comwrote in message
news:Od**************@TK2MSFTNGP06.phx.gbl...
Hello!

So you mean I first start the asp.net web application from my local IIS
which is from within VS.
I just wonder at what point do I attach to the process w3wp you meantioned
in your main
Yes you'll need to make at least one request into the app to get it spun up.
If you are using XP its not called w3wp.exe it will called aspnet_wp.exe in
which case you need to make at least one request that invokes a .NET handler
such as an aspx or ashx request.
--
Anthony Jones - MVP ASP/ASP.NET

Nov 4 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Jorge | last post by:
Hi, I'm developing a web page application that runs 2 processeses. These two process create postcript files, the first one creates a map and the second one overlays data over that map. ...
0
by: Amrendra | last post by:
Hi Friends ! Can anyone help? Its an urgent. I wanted to print PDF Document or Scanned Document Through my .aspx page .By just clicking a button.I'm not using codebehind.I want to do printing at...
0
by: Amratash | last post by:
Hi, I needyour help.Its urgent. My main aim is to log the site activities in a database at runtime. I'm using W3C Extended Log File format for logging information. I can use ODBC Logging directly...
16
by: | last post by:
Hi all, I have a website running on beta 2.0 on server 2003 web sp1 and I keep getting the following error:- Error In:...
15
by: Cheryl Langdon | last post by:
Hello everyone, This is my first attempt at getting help in this manner. Please forgive me if this is an inappropriate request. I suddenly find myself in urgent need of instruction on how to...
2
by: Martin | last post by:
Hello, We are in the process of putting together an A class PHP Development team(ecommerce / billing applications) for a project in the Bay Area. Reqt. details: ReqId : Req-3616 - Senior PHP...
0
by: sanjayhire | last post by:
Hi All, I have just joined the forum. I need your help..As it's very urgent... How to identify a particular process is running on a server(Windows/Unix server) using VB program and since how...
1
by: jewel87 | last post by:
Hello everyone, I have problems with my code in C doing pipes. It is currently running into an indefinite loop, but I was trying all possible modifications I could think of, nothing have led me to...
1
by: javabeginner123 | last post by:
i have a java prob, and i have to solve it fast, but i'm just getting to know it, so plz help me solve it with full code completed, thanks so much. the prob is to create a monter fight and there is...
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...
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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
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...

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.