console

How do I open a new console window for a Visual C++ console application?

What I want to do is something like this: ConsoleWindow1.Print("1"); ConsoleWindow2.Print("2"); When I run the program, two console windows pop up and one gets printed with 1 and the other gets printed with 2. Is there a simple way of doing this? ...

Is there a better alternative to Console.ReadKey()?

Most programming books will tell you to use Console.ReadKey() to pause the console, but is there a better alternative? Console.WriteLine("Press any key to continue."); Console.ReadKey(); ...

How do you log to Firebug from an extension?

I'm writing an extension for Firefox, and I need to log some data to Firebug's console. Within the scope of my addon, "console" is undefined, and "window.content.console" is also undefined. So how do I log to the console? ...

Java Exception printing twice

I know the exception is kind of pointless, but I was trying to learn how to use / create exceptions so I used this. The only problem is for some reason my error message generated by my exception is printing to console twice. import java.io.File; import java.io.FileNotFoundException; import java.io.PrintStream; import java.util.Scanner; ...

Is there a way to inject behavior to csrss.exe and modify/enhance windows console?

I'm aware of Console2 and similar solutions, but I would really like to enhance every console window in my system. Any ideas? ...

Open a new tab in gnome-terminal using command line.

Hi, When I write gnome-terminal --tab at the terminal, I expect it to open a new tab in the same terminal window. But it opens a new window instead. I found out that its intention is to open a new tab in a new window, i.e., if I write gnome-terminal --tab --tab it will open a new window with two tabs. So, the question is...

C++ interpreter / console / snippet compiler

Hi, I am looking for a program where I can enter a C++ code snippet in one window, press a button, and get output in another window. Compilation should somehow be hidden behind the button. On a per-snippet basis would be fine, full interactive probably asking too much. It should run under Linux/Unix. Main use case would be learning/tes...

Refreshing values in the console

I don't know how to explain this very well, but here's a shot at it. Don't hesitate to ask for clarification, please. Suppose I have a console that displays numbers that change with certain events. The best example would be a "plane" instrument that shows altitude, direction, wind, etc. Like so: Altitude: 9876ft Direction: NE Wind...

In a Console App, is there a way to detect when StandardInput is available?

I wanna build a console app that may stop and prompt for some input, under some conditions. But I want to prompt only if input will be available. Is there a way to know if Stdin is connected to anything? I think powershell does this, and I'd like to do something similar. Powershell detects when it is run interactively, and prompts...

Why is System.console() set if executed with java and unset if executed via ant?

I wrote a little commandline-application in Java and wanted to use the new class java.io.Console for this. I use System.console() to get an instance of this class. This call returns a working console, if I call my application via 'java -jar MyApp.jar' but is unset if I execute the application via the java-task of ant. fork is true and sp...

what is wrong with find . | xargs grep '...'?

When i use the command above, i get wrong matches.....can someone explain me, what is wrong? I'm trying to search for the string "..." in all files in the current folder. ...

Java - Control console output in windows/linux

Does Java support controlling the cursor when outputting to a console? For example, I'd like to set the character position, and possibly color, before doing a System.out.print(). Think of the way an application like top writes to the console. Thanks! ...

Any good Ruby console application gems out there?

I'm digging around trying to find a good set of tools for creating console applications, as most of the settings I expect to be using Ruby in the coming months won't be webapps, but server-side scripts. I know of highline, and I do plan on using that for user and possible password prompts, but I know that the Console application world s...

Delphi 6 - read console app's output while running

How do I read a console apps output as it is running. I start the console application and would like to read the output as it is printed by the console app. ...

How can I pipe console output to an ASP.NET page as it appears?

I'd like to run a console program from an ASP.NET page, pipe the output into a label or some other control, and have it updated dynamically as each Console.Writeline happens. How do I do that? ...

How does a .NET console application look for referenced assemblies?

I created a console application using C# that references external DLLs. When I run it on my dev machine, everything works fine. On the production machine, I get a "type initiatization" error. Looking into this, it seems it may because the app can't find the referenced DLLs. On my dev box, the referenced DLLs are in the GAC, but not on t...

How to quickly and conveniently disable all console.log statements in my code?

Is there any way to turn off all console.log statements in my JavaScript code, for testing purposes? Thanks! ...

rails console doesn't load

Today, for no reason, my rails(2.1.0) application is very slow or even not responding. It happens intermittently. So sometimes it works but again it doesn't work. When it doesn't work, I can't even load 'script/console production'. I want to know where it's stuck. How do I load console step-by-step so that I can know which part causes t...

java console menu

I'm writing a java console menu. however, my jre doesn't support "Scanner". What is the walk around to this problem? java.util.Scanner scanner = new Scanner (System.in); ...

How do I display more decimals in the output console?

I want to output the value of a double in it's full precision. However, when using the cout function, it only displays the first 6 digits even though there is around 15-16 digits of precision. How do i get my program to display the entire value, including the magnitude (power) component? Thanks in advance, -Faken ...