Command Lines?
- Grimdoomer
- Admin
- Posts: 1835
- Joined: Sun Dec 09, 2007 9:09 pm
Command Lines?
I want to add a Command Promt to my app, so when I am testing things that take a long time to get to I could just use the cmd prompt. I also might leave it in for other features. What I am wondering is how do I add a cmd line to my currect project? do I just make a new cmd project and add it?
Don't snort the magic, we need it for the network.
- Prey
- Posts: 129
- Joined: Sat Dec 29, 2007 5:06 pm
- Location: UK
Re: Command Lines?
Build> Properties> Build Events
- Grimdoomer
- Admin
- Posts: 1835
- Joined: Sun Dec 09, 2007 9:09 pm
Re: Command Lines?
Yea but I want more of a console, so i could put in commands like Build Buildpath so it would build a tag into the map.
EDIT: I got it, and its so easy.
EDIT: Well now i cant get this dam keypress procedure to work.
I create a keypress meathod with the events window, then I add the folowing code:
but when I press F2 it doesent work.
EDIT: I got it, and its so easy.
EDIT: Well now i cant get this dam keypress procedure to work.
I create a keypress meathod with the events window, then I add the folowing code:
Code: Select all
switch (e.KeyCode)
{
case Keys.F2:
{
//Run the Oracle Console
//new Oracle_Console.Program.Main();
MessageBox.Show("ggdfgg");
break;
}
}
Don't snort the magic, we need it for the network.
-
- Posts: 18
- Joined: Fri Feb 22, 2008 4:20 am
Re: Command Lines?
what did you set the keys object to, Example if it were the form then make sure the form have focus
- OwnZ joO
- Posts: 1197
- Joined: Sun Dec 09, 2007 4:46 pm
Re: Command Lines?
With console I think you want to perform a readline, havent worked with it much though.
- Grimdoomer
- Admin
- Posts: 1835
- Joined: Sun Dec 09, 2007 9:09 pm
Re: Command Lines?
Yea I know that, but the main problem is I need both the console project and my main project to have references to each other. But then I get an error about having a circle reference.
Don't snort the magic, we need it for the network.
-
- Posts: 18
- Joined: Fri Feb 22, 2008 4:20 am
Re: Command Lines?
well I will try to do what your saying but, Trying referencing the 'Console' class in C# and maybe write to it (EX: Colsole.WriteLine(line to write);) idk if that will work but try,
and yes thed: Console.ReadLine(); function makes it so the command promt window doesnt close
and yes thed: Console.ReadLine(); function makes it so the command promt window doesnt close
- Grimdoomer
- Admin
- Posts: 1835
- Joined: Sun Dec 09, 2007 9:09 pm
Re: Command Lines?
I got it all to work a long time ago, except that I cant add references to both projects because ill create a circle reference. So will never work.
Don't snort the magic, we need it for the network.