Questions tagged [console-application]

A console application is a computer program designed to be used via a text-only computer interface, such as a text terminal, the command line interface of some operating systems (Unix, DOS, etc.) or the text-based interface included with most Graphical User Interface (GUI) operating systems, such as the Win32 console in Microsoft Windows, the Terminal in Mac OS X, and xterm in Unix.

A console application is a computer program designed to be used via a text-only computer interface, such as a text terminal, the command line interface of some operating systems (Unix, DOS, etc.) or the text-based interface included with most Graphical User Interface (GUI) operating systems, such as the Win32 console in Microsoft Windows, the Terminal in Mac OS X, and xterm in Unix. A user typically interacts with a console application using only a keyboard and display screen, as opposed to GUI applications, which normally require the use of a mouse or other pointing device. Many console applications such as command line interpreters are command line tools, but numerous text-based user interface (TUI) programs also exist.

As the speed and ease-of-use of GUI applications have improved over time, the use of console applications has greatly diminished, but not disappeared. Some users simply prefer console based applications, while some organizations still rely on existing console applications to handle key data processing tasks.

7241 questions
12
votes
3 answers

Must declare the table variable @table

I'm a beginner in C# and SQL, i have this SQL insert statement that i want to perform. It asks for the table name among the other variables that i want to insert. But when i run this console app i get this error : Must declare the table variable…
Rafael Adel
  • 7,673
  • 25
  • 77
  • 118
12
votes
3 answers

Create Image or Bitmap in console application - can't seem to find System.Drawing?

I'm trying to create an image or bitmap from a camera bitstream that I will be (hopefully) passing to the browser via a websocket. The application I'm building is a console app as I didn't think there would be a need for this app to have a GUI. Now…
HowDoIDoComputer
  • 1,383
  • 1
  • 10
  • 19
12
votes
1 answer

What's wrong with consuming ConfiguredTaskAwaitable from PortableClassLibrary's class under Debugger from MSTest Runner or Console App?

Note: This is only a Debug-time error, but a very weird one. Problem: While running with Debugger attached and calling a method, exposed in separate Portable library, returning ConfiguredTaskAwaitable, we get InvalidProgramException. Reproduce…
12
votes
2 answers

Calling Environment.Exit() Within a Using Block

If I have a console application with code like: using (DisposableObject object = new DisposableObject()) { if (a condition) Environment.Exit(0); // Do Stuff } Will my object be properly disposed? Or does the thread die before the object…
RJ Cuthbertson
  • 1,458
  • 1
  • 20
  • 36
12
votes
2 answers

How can I specify the window position of an external console program?

In my Win32 VCL application I am using ShellExecute to launch a number of smaller Delphi console applications. Is there a way to control the position of those console windows? I would like to launch them centered on screen.
user1593881
12
votes
2 answers

Passing lengthy strings (as an argument) into a console application

I'm creating a console application in C# to which, at execution, it is passed a bunch of data. Three of them are short strings, such as username, password, etc. However, one of them is a rather lengthy XML document. How long can the strings be, when…
11
votes
2 answers

Console.ReadLine("Default Text Editable Text On Line")

Is there way of achieving this? I want to pass some text and have it appear on the input line -- instead of "Enter your Name:", I want "Enter your Name:Default Editable Text"
Mark Robbins
  • 2,427
  • 3
  • 24
  • 33
11
votes
4 answers

Infrequent hangs in a multi-threaded C# console application when using Console.Writeline() or Console.Write()

I have written a console application that makes use of console.write and console.writeline to provide some logging. The application is a server application that uses asynchronous beginacceptconnection() and beginread() ( Sockets ) for communication.…
11
votes
1 answer

How to add values through user secrets to an array of objects in C#

So I'm having issues trying to get Visual Studio to add user secrets to a property that is an array. I have a feeling this sort of thing can't be done but I really need to have a way of iterating through the each of them for what I'm doing and I'm…
11
votes
8 answers

Is a console user interface in .net possible?

I am wondering whether there are libraries in .NET that make it easy to write console user interfaces. For instance, imagine a WinForms application, where the user can: Navigate the menus Respond to dialogs And the application in return displays…
mark
  • 59,016
  • 79
  • 296
  • 580
11
votes
2 answers

Python Console UI Suggestions

I'm currently rewriting a perl console application that was using curses, and planning to implement it in Python. So far I've narrowed my library options to straight curses, urwid, and dialog. The application is basically an installer for an…
dkw22
  • 111
  • 3
11
votes
1 answer

How to execute child console programs without showing the console window from the Win32 GUI program?

(I've searched SO answers and found no clear solution to this problem.) I'm working on a MFC GUI program. This program runs various child programs including console program and shell command script(.cmd). Initially it displayed one GUI window and…
9dan
  • 4,222
  • 2
  • 29
  • 44
11
votes
2 answers

Visual Studio 2017 c++ win32 console project template

I am on Visual Studio Community 2017 v. 15.3.1 and I can't seem to find Win32 console application or Win32 project. Still have empty c++ project template and Windows Console Application template. On the start page, I still have win 32 console…
11
votes
4 answers

Integrate a C# console application with a GUI

I've been developing using C# from scratch for less than 3 months and what I got at present is a console application made with Visual Studio 2015. This application consumes a web service, the XML is deserialized, formatted and saved in an Access…
11
votes
3 answers

How to use colours in console output in Scala or Java?

How to use colours in console output in Scala or Java?
Ivan
  • 63,011
  • 101
  • 250
  • 382