console

Is GlassFish Admin console (port 4848) secure?

With understanding of secure Internet connections limited to SSL, I'm doubtful about the security of GlassFish Admin console. Normal secure HTTP connections use http**s**://domain/ URLs but in GlassFish http://domain:4848/ is used to login to Admin console. Is there some kind of encryption going on between the browser and the server when...

How to write to the Console input and get the Console Handle?

I want the user to be able to have some data already in the input stream that they can change. I looked into the below function, but I'm not sure how to get the Console handle from the Console class. [DllImport("kernel32", CharSet = CharSet.Auto, SetLastError = true)] public static extern bool WriteConsoleInput( IntPtr ...

How To: Best way to draw table in console app (C#).

Hello there, I have an interesting question. Imagine I have a lot of data changing in very fast intervals. I want to display that data as a table in console app. f.ex: ------------------------------------------------------------------------- | Column 1 | Column 2 | Column 3 | Column 4 | --------------------...

Making all variables in a program modifiable at runtime by the programmer, smart idea?

I was thinking of doing this with C++, basically from an external editor or something the programmer can say: MyClass::dude = "hello" where 'dude' is a static integer in 'MyClass'. What the program does at runtime is it partitions the input to MyClass :: dude = "hello" and finds the class called 'MyClass' and assigns the dude variable i...

C# Console App Session/Storage

What would be the best way to implement a psuedo-session/local storage class in a console app? Basically, when the app starts I will take in some arguments that I want to make available to every class while the app is running. I was thinking I could just create a static class and init the values when the app starts, but is there a more e...

What is the easiest way to get an int in a console app?

I want to process user input as an integer, but it seems as though C has no way to get an int from stdin. Is there a function to do this? How would I go about getting an int from the user? ...

Read input from a cocoa/foundation tool console?

I wonder if Objective-C/Foundation has any special commands for reading user input from the console. Since it has NSLog for output maybe there is something else I could use instead of the scanf command. I need to read some numbers (user input) into my tool. What is the best way to get these input in types like double or int? And how do ...

Can't run ruby script/console

I get this error when trying ruby script/console "Rails requires RubyGems >= . Please install RubyGems and try again:" I expect this has something to do with the $PATH, however, I don't know what to do? I'm running ruby 1.8.6 and rails 2.3.2. I'd appreciate any help, thanks! ...

Stop a .net console app from being closed

Is there any way to stop a .NET console app from being closed? I've got an app that follows this pattern: while (true) { string x = Console.ReadLine(); StartLongRunningTaskOnSeparateThread(x); } The problem is that it's possible to close the console window (and therefore cut off the long running task). Is there an equivilent o...

How to detect .Net application type?

I have a library that needs to respond to exceptions in different ways depending on whether it is running in a Console app, WinForms, AspNet or Windows Service. I have experimented with looking at various properties in the System.Windows.Forms and System.Web namespaces, but I can't find a reliable way of detecting exactly which kind of ...

add a web service reference to a console app

Im creating a simple web service in a console app. (PersonService) this is my Program.cs below im trying to add a service reference to a different console app (PersonClient) how can i do this? i tried adding it by right clicking, add service reference, pointing to the refernce etc... but it wont work. [DataContract] pu...

How can I update the current line in a C# Windows Console App?

When building a Windows Console App in C#, is it possible to write to the console without having to extend a current line or go to a new line? For example, if I want to show a percentage representing how close a process is to completion, I'd just like to update the value on the same line as the cursor, and not have to put each percentag...

Print Coloured Text to Console in C++

I would like to write a Console class that can output coloured text to the console. So I can do something like (basically a wrapper for printf): Console::Print( "This is a non-coloured message\n" ); Console::Warning( "This is a YELLOW warning message\n" ); Console::Error( "This is a RED error message\n" ); How would I print different...

C# Console: Write while reading and retain structure.

I am writing a C# console application that connects to a server trough TCP, it uses a separate thread to listen for incoming messages from the server and I want it to write them to the console while at the same time reading a message from the console. I was able to do that, but I have a problem. The console displays this while I type an...

C# How To Read Console Output With Parameters

Is it possible to run a console application and get its outputted contents back as a string in C#? I want to be able to use parameters when running the console app: c:\files\app.exe -a 1 -b 2 -c 3 ...

Is there a way to read input directly from the keyboard in standard C++?

And I know there's std::cin, but that requires the user to enter a string, then press ENTER. Is there a way to simply get the next key that is pushed without needing to press ENTER to confirm ...

Eclipse console: detect warning and error patterns and make them clickable

I'm running the flex compiler (mxmlc) from ant inside eclipse for some of our builds (they are meant to run on our continuous integration server as well, that is why I don't build using flex builder itself) -- the patterns of mxmlc are not recognized by the eclipse-console, so I cannot click on them. The patterns is like this: <absolut...

Linux - communicating with a process? rejoin process in action?

I feel somewhat dumb asking this, but I'm relatively new to linux (more in terms of experience than time), and one thing that i've always wondered is if I can 'rejoin' (my own term) a process while it's running. For example, if I set a game server or eggdrop IRC bot to run in the background, is there a command I can use to view that pr...

Exchange 2007 Not Allowing Mail To Be Sent From Console App

I am trying to send email using Exchange 2007 from a console app using the following code and I get this error message in the exception that gets thrown on the Send call. The SMTP server requires a secure connection or the client was not authenticated. The server response was: 5.7.1 Client was not authenticated MailMessage ...

What exactly is the effect of Ctrl-C on C++ Win32 console applications?

Is it possible to handle this event in some way? What happens in terms of stack unwinding and deallocation of static/global objects? ...