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

running c# executable....

fellow c# programmers...

i need some help....
i have created a program, a module that is part of another bigger
program...
when i debug it, by pressing F5 in the IDE, it runs so well i can
hardly wait to show it to my project leader...
but when i try to run the executable created by the IDE, the .exe file
in the Debug folder, it catches exceptions and stops the program...

what bothers me so much is that:
1) it runs so well when i debug it(pressing F5 in the IDE), but the
..exe file doesnt...
2) my deadline is already here!!!!!!!

please tell me what to do with this one....
thanks in advance...

Nov 17 '05 #1
14 1760
You're going to need to ask specific questions in order to get help, I
think. We'll need to see your code.

tracernet_v2 wrote:
fellow c# programmers...

i need some help....
i have created a program, a module that is part of another bigger
program...
when i debug it, by pressing F5 in the IDE, it runs so well i can
hardly wait to show it to my project leader...
but when i try to run the executable created by the IDE, the .exe file
in the Debug folder, it catches exceptions and stops the program...

what bothers me so much is that:
1) it runs so well when i debug it(pressing F5 in the IDE), but the
.exe file doesnt...
2) my deadline is already here!!!!!!!

please tell me what to do with this one....
thanks in advance...

Nov 17 '05 #2
"jeremiah johnson" wrote:
You're going to need to ask specific questions in order to get help, I
think. We'll need to see your code.

ok then...
i just want to ask for some tips on what to do regarding this matter...
as for the source code, i do not think i could, the project is a bit
classified...

but i just would like to ask if you guys had encountered this one...
when i try to debug the program, that is by pressing F5 in the IDE, the
program works very fine and runs without throwing any exception...

as we know the IDE would create the equivalent executable file in the
Debug folder of the working folder right...?
when i try to run that executable file, it runs smoothly but throws some
exceptions which had been filtered already...
i can see the executable catches some errors when it shouldnt have...

please help... give me some tips on what to do with this...

acem-tracernet
software devt staff

C# programmer

--
Sent via .NET Newsgroups
http://www.dotnetnewsgroups.com
Nov 17 '05 #3
tracernet_v2 <hy******@gmail.com> wrote:
fellow c# programmers...

i need some help....
i have created a program, a module that is part of another bigger
program...
when i debug it, by pressing F5 in the IDE, it runs so well i can
hardly wait to show it to my project leader...
but when i try to run the executable created by the IDE, the .exe file
in the Debug folder, it catches exceptions and stops the program..


As ever, if you've got exceptions you don't understand, it would really
help if you could at least tell us what those exceptions are.

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
Nov 17 '05 #4
"Jon Skeet [C# MVP]" wrote:

As ever, if you've got exceptions you don't understand, it would really
help if you could at least tell us what those exceptions are.


actually, i have understood the exceptions, i had even trapped them....
but my real problem is that the executable catches exceptions(i had
trapped before) and end immaturely....
it bugs me because when i try debugging the program while it is in
development stage, that is when i press F5 in the IDE, the program runs
smoothly without any exception to immaturely end it...

-----
acem-tracernet
software devt staff

C# programmer

--
Sent via .NET Newsgroups
http://www.dotnetnewsgroups.com
Nov 17 '05 #5
tracernet_v2 <hy******@gmail.com> wrote:
As ever, if you've got exceptions you don't understand, it would really
help if you could at least tell us what those exceptions are.


actually, i have understood the exceptions, i had even trapped them....
but my real problem is that the executable catches exceptions(i had
trapped before) and end immaturely....
it bugs me because when i try debugging the program while it is in
development stage, that is when i press F5 in the IDE, the program runs
smoothly without any exception to immaturely end it...


That doesn't really help us to pin down what's wrong though, does it?
Effectively, you've just given us:

"My program works in the debugger but doesn't work outside the
debugger."

Can you see how that makes it rather difficult to help you without any
more information?

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
Nov 17 '05 #6
"Jon Skeet [C# MVP]" wrote:
tracernet_v2 <hy******@gmail.com> wrote: That doesn't really help us to pin down what's wrong though, does it?
Effectively, you've just given us:

"My program works in the debugger but doesn't work outside the
debugger."

Can you see how that makes it rather difficult to help you without any
more information?


yes... yes... that is it!!!!
that is my problem...
My program works in the debugger but doesn't work outside the
debugger...
can you help me? can you give me some tips on how to deal with this
problem????

thanks so much in advance....

-----
acem-tracernet
software devt staff

C#-VB.NET programmer

--
Sent via .NET Newsgroups
http://www.dotnetnewsgroups.com
Nov 17 '05 #7
tracernet_v2 <hy******@gmail.com> wrote:
"Jon Skeet [C# MVP]" wrote:
tracernet_v2 <hy******@gmail.com> wrote:
That doesn't really help us to pin down what's wrong though, does it?
Effectively, you've just given us:

"My program works in the debugger but doesn't work outside the
debugger."

Can you see how that makes it rather difficult to help you without any
more information?


yes... yes... that is it!!!!
that is my problem...


Yes, and the problem *we've* got is that that's just not nearly enough
information.

What would you do if a developer said to *you*: "My program doesn't
work. What's wrong?"
My program works in the debugger but doesn't work outside the
debugger...
can you help me? can you give me some tips on how to deal with this
problem????


I suggest you start cutting down your program until you've got a short
but complete program which demonstrates the problem. That program will
almost certainly not need to have anything confidential in it, which
means you'll be able to post it here, if you haven't already found the
answer by going through the exercise in the first place.

See http://www.pobox.com/~skeet/csharp/complete.html

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
Nov 17 '05 #8
"Jon Skeet [C# MVP]" <sk***@pobox.com> wrote in message
news:MP************************@msnews.microsoft.c om...

yes... yes... that is it!!!!
that is my problem...


Yes, and the problem *we've* got is that that's just not nearly enough
information.


It must be a wind up Jon.

He'll probably tell us that it's a System.VagueException.

--
Regards,

Tim Haughton

Agitek
http://agitek.co.uk
http://blogitek.com/timhaughton
Nov 17 '05 #9
ok...
thanks for the suggestion...
i will try to do that...

but any way, my problem is very similar to that one...
my program works well in the debugger, but it doesnt work outside the
debugger...
so for now i would like to ask if you have gone through that one, and
what did you do.. did you do something to the properties or any thing
around the debugger...?

just want to know....

-----
acem-tracernet
software devt staff

C#-VB.NET programmer

--
Sent via .NET Newsgroups
http://www.dotnetnewsgroups.com
Nov 17 '05 #10
Ignore the debugger, you can't ship your IDE with the product. Write your
unity tests and run them against the release executable. They will help you
find your problem. Things in .Net are rarely mystical. You'll be doing
something wrong.

--
Regards,

Tim Haughton

Agitek
http://agitek.co.uk
http://blogitek.com/timhaughton
"tracernet_v2" <hy******@gmail.com> wrote in message
news:ut**************@TK2MSFTNGP10.phx.gbl...
ok...
thanks for the suggestion...
i will try to do that...

but any way, my problem is very similar to that one...
my program works well in the debugger, but it doesnt work outside the
debugger...
so for now i would like to ask if you have gone through that one, and
what did you do.. did you do something to the properties or any thing
around the debugger...?

just want to know....

-----
acem-tracernet
software devt staff

C#-VB.NET programmer

--
Sent via .NET Newsgroups
http://www.dotnetnewsgroups.com

Nov 17 '05 #11
"Tim Haughton" wrote:
Ignore the debugger, you can't ship your IDE with the product. Write yourunity tests and run them against the release executable. They will help youfind your problem. Things in .Net are rarely mystical. You'll be doing
something wrong.

i am new to this words, so could you please explain to me this phrases:

"Write your unity tests and run them against the release executable. "

"Things in .Net are rarely mystical. You'll be doing something wrong."

hope you could enlighten me with these....

-----
acem-tracernet
software devt staff

C#-VB.NET programmer

--
Sent via .NET Newsgroups
http://www.dotnetnewsgroups.com
Nov 17 '05 #12
tracernet_v2 wrote:
ok...
thanks for the suggestion...
i will try to do that...

but any way, my problem is very similar to that one...
my program works well in the debugger, but it doesnt work outside the
debugger...
so for now i would like to ask if you have gone through that one, and
what did you do.. did you do something to the properties or any thing
around the debugger...?


There are *lots* of different reasons why it might be happening - but
without any more information from you, we just won't be able to help
you any further. Can't you at least tell us what the exception is?

Jon

Nov 17 '05 #13
"Jon Skeet" wrote:

There are *lots* of different reasons why it might be happening - but
without any more information from you, we just won't be able to help
you any further. Can't you at least tell us what the exception is?

Jon


ok... here it is...

the first exception said that "Input string is in invalid format."

the next one said that it "cannot find the file <file name>", a file
that is existing all along....

the other one said that it "cannot proceed because the file <file name>
is used by another process"

please keep in mind that these exceptions occur outside the
debugger/IDE, that when i run the executable file itself these
exceptions occur, and the program works will with the debugger...

i am using Visual Studio 2003 IDE....

-----
acem-tracernet
software devt staff

C#-VB.NET programmer

--
Sent via .NET Newsgroups
http://www.dotnetnewsgroups.com
Nov 17 '05 #14
> ok... here it is...

Finally, some information!
the first exception said that "Input string is in invalid format."
At which point? What input string? Is this a problem you've fixed?
the next one said that it "cannot find the file <file name>", a file
that is existing all along....
How are you referring to it? The working directory of the process
may well be different when running in a debugger...
the other one said that it "cannot proceed because the file <file name>
is used by another process"


That sounds like you may not be disposing of FileStreams (and the like)
properly - the debugger may be garbage collecting earlier than when you
run it outside the debugger.

Jon

Nov 17 '05 #15

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

Similar topics

7
by: Johnny | last post by:
How do I create a link on a Web page on my hard drive that will run an executable file on my hard drive? For example, let's say I create runpoodle.htm and save it to my hard drive, and let's...
6
by: foldface | last post by:
Hi Sorry, don't know how to phrase the question any better. Within Visual Studio I have a style sheet that being dynamically added to the code, i.e. not via the html page. I want to place this...
3
by: BobAchgill | last post by:
I am using FTP built in to my application to update the application and data from a server... What is the normal method folks use to over write the application while the program is active? What...
4
by: Jeremy S. | last post by:
We're in the process of writing a new Windows Forms app and the desktop support folks want for it to be run from a network share. I know it's possible (i.e., just have the framework on the clients...
17
by: Csaba Gabor | last post by:
Is there a way to determine the path to the php executable (as opposed to the script. In other words, I am looking for the path to php.exe or php-win.exe) that is currently running (ie. how was...
9
by: Andrzej | last post by:
Greetings. Is there any project of universal environment for running programs written in C++ ? For example a programmer compiles program using compilator and linker that produces universal...
10
by: jon | last post by:
I am a beginner C programmer, this is actually my first programming lanugage, besides html, cgi, and javascript. I am looking for a way to make an .exe file, or a copy of my own file. I have tried...
4
by: somank.sharma | last post by:
I am running an exe created in C. I need the full path (absolute path) of this exe. In the first argument of main, I am getting the exe name. How can I get the full path for this exe.
2
by: NasirMunir | last post by:
I am trying to run an executable using shell. The executable look for certain files in the same directory and then run on those files. My problem: I have created a form which asks from the user to...
4
by: Brad Pears | last post by:
I have a vb.net 2005 project and have made a lot of modifications to it. The project runs fine in debug mode. Now I want to implement it and first I am running the executable on my machine to make...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
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...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
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...

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.