473,320 Members | 1,838 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.

c# program execution

Hi,
I have been developing a game using C#. When I execute the .exe program
file, I get a console/command prompt open up alongside the actual program as
you may know. This console is invaluable for debugging purposes, however I
want to know if there is any way of stopping the console from appearing, so
that in my final version of the game I have just my program running.

Thanks in advance,
Junaid
Nov 16 '05 #1
5 1332
I guess you're using a command line compile. Use the /w switch to make a
windows executable.

--
Bob Powell [MVP]
Visual C#, System.Drawing

Find great Windows Forms articles in Windows Forms Tips and Tricks
http://www.bobpowell.net/tipstricks.htm

Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/faqmain.htm

All new articles provide code in C# and VB.NET.
Subscribe to the RSS feeds provided and never miss a new article.

"Junaid Hussain" <ju************@gmail.com> wrote in message
news:CZ*************@newsfe2-gui.ntli.net...
Hi,
I have been developing a game using C#. When I execute the .exe program
file, I get a console/command prompt open up alongside the actual program as you may know. This console is invaluable for debugging purposes, however I
want to know if there is any way of stopping the console from appearing, so that in my final version of the game I have just my program running.

Thanks in advance,
Junaid

Nov 16 '05 #2
Hello Junaid,

This is because you have created a "Console Application" C# project instead
of a "Windows Application" C# project.
That's why you get the command prompt window.
Emmanuel
"Junaid Hussain" <ju************@gmail.com> wrote in message
news:CZ*************@newsfe2-gui.ntli.net...
Hi,
I have been developing a game using C#. When I execute the .exe program
file, I get a console/command prompt open up alongside the actual program
as you may know. This console is invaluable for debugging purposes,
however I want to know if there is any way of stopping the console from
appearing, so that in my final version of the game I have just my program
running.

Thanks in advance,
Junaid

Nov 16 '05 #3
Hi,
Thanks for the reply. Sorry but im not sure how to use the /w switch at the
command line. At the moment i'm compiling my program using;

csc pool.cs
which results in a pool.exe file. Where do I add the /w switch?

Thanks,
"Bob Powell [MVP]" <bob@_spamkiller_bobpowell.net> wrote in message
news:u6**************@TK2MSFTNGP15.phx.gbl...
I guess you're using a command line compile. Use the /w switch to make a
windows executable.

--
Bob Powell [MVP]
Visual C#, System.Drawing

Find great Windows Forms articles in Windows Forms Tips and Tricks
http://www.bobpowell.net/tipstricks.htm

Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/faqmain.htm

All new articles provide code in C# and VB.NET.
Subscribe to the RSS feeds provided and never miss a new article.

"Junaid Hussain" <ju************@gmail.com> wrote in message
news:CZ*************@newsfe2-gui.ntli.net...
Hi,
I have been developing a game using C#. When I execute the .exe program
file, I get a console/command prompt open up alongside the actual program

as
you may know. This console is invaluable for debugging purposes, however
I
want to know if there is any way of stopping the console from appearing,

so
that in my final version of the game I have just my program running.

Thanks in advance,
Junaid


Nov 16 '05 #4
Hi,
How can I create a Windows Application. I am compiling my program from the
command prompt by ;
csc pool.cs,

Thanks once again

"Emmanuel" <z> wrote in message
news:Od**************@TK2MSFTNGP12.phx.gbl...
Hello Junaid,

This is because you have created a "Console Application" C# project
instead of a "Windows Application" C# project.
That's why you get the command prompt window.
Emmanuel
"Junaid Hussain" <ju************@gmail.com> wrote in message
news:CZ*************@newsfe2-gui.ntli.net...
Hi,
I have been developing a game using C#. When I execute the .exe program
file, I get a console/command prompt open up alongside the actual program
as you may know. This console is invaluable for debugging purposes,
however I want to know if there is any way of stopping the console from
appearing, so that in my final version of the game I have just my program
running.

Thanks in advance,
Junaid


Nov 16 '05 #5
Try this:

csc /t:winexe pool.cs

--
Ian Griffiths - http://www.interact-sw.co.uk/iangblog/
DevelopMentor - http://www.develop.com/

"Junaid Hussain" wrote:
How can I create a Windows Application. I am compiling my program from the
command prompt by ;
csc pool.cs,

Nov 16 '05 #6

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

Similar topics

4
by: Bruce W...1 | last post by:
A scripting newbie question... I'm trying to understand some code I found. This script conducts a poll and writes the results to a text file. The following statement is part of the source file. ...
3
by: Daragoth | last post by:
Hi, I'm writing a program using Metrowerks CodeWarrior 4.0 that determines the best possible combination of a data set by checking every possible combination. I found there were about 250,000,000...
6
by: shoo | last post by:
Any one know how to do this? thank Write a simple text-formatting program that produces neatly printed output from input text containing embedded command lines that determine how to format the...
1
by: Eric M | last post by:
Hi, I am new to c++ programming with Windows and I need to know if its possible to close applications or delay their execution from a seperate program. Ideally, I would want to pause the...
6
by: shoo | last post by:
Any one know how to do this? thank Write a simple text-formatting program that produces neatly printed output from input text containing embedded command lines that determine how to format the...
12
by: Thomas Carter | last post by:
Is it possible, in an OS-independent way, to suspend a C program for some specified amount of time, in such a way that CPU load, due to this program, while remaining suspended, is non-existant or,...
8
by: lovecreatesbea... | last post by:
K&R 2, sec 2.4 says: If the variable in question is not automatic, the initialization is done once only, conceptually before the program starts executing, ... . "Non-automatic variables are...
12
by: greg | last post by:
Hi, Can anyone help me with the following issue: How can I pause the execution of a program until a given file is created (by another process) in a specified directory? Any ideas would be...
4
by: sulekhasweety | last post by:
Hi, can any one give a brief outline of the different stages in the execution of a C program , in terms of compilation, pre-processing, linking etc
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
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
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
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: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
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...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

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.