Console Applications


I have just began to dabble in the world of C# and am using the Microsoft Step By Step C# 2010 book to assist my learning!

I have just finished the chapter on console applications, all it taught me was the details of Visual Studio which were good to know; and how to write a very basic Console.WriteLine("Hello World"); console application, (honestly these Hello World examples are going to kill me).

My question is, I understand that WPF applications are far more modern than console applications, but i cant help but feel that Console Applications could serve a purpose if you need to run a basic programme or whatever. So it's great, i know how to write a very basic console application that executes a line of code when you run it, but like i say i cant help but feel there could be a bit more of the basics to learn with console applications before I move on to WPF applications, some a little more advanced that i can do with console apps that is worth knowing at this stage of my development.. It could be that i'm jumping the gun and once i learn WPF Apps it'll tie in, i don't know, but is there any beginners tips or things you suggest worth learning that isn't going to confuse the living day lights out of me (Baring in mind i am a complete novice with C#).

Who is Participating?
Ron MalmsteadInformation Services ManagerCommented:
A console application can be as robust or simple as you like.
The only real difference between a console app and any other program .. for example winforms program.. is that it has no forms, .. no "UI".  Typically they are created for commandline utility type purposes, but you can for example.. create a console application that is an e-mail server engine, or a network proxy server.  Backend-wise it can do anything any other type of program or project can do if you program it to do so.  So don't think of a console app as a "beginner's" development.. it's just a different technology.

WPF, however, is an entirely different animal.  You're comparing a localized application to a web browser application based platform.  They behave differently, they have different considerations for coding practices, and they are used for completely different purposes, though much of the fundamentals of coding are there for both.

If your ultimate goal is to learn WPF, I say jump right in...
SuperJinxAuthor Commented:
Great, i think i should just wait i know how a console app works now, when it's necessary i'm sure i'll learn what i need to learn about them.

Whilst you're helping, i'm creating my first WPF app, this book asks me to "Click the form in the Design VIew Window and then display the toolbook again" "In the toolbox click and drag the textbox control onto the form."
This seems unbelivably easy yet i can not decipher how it's done?! How do i display the toolbox 'again' and how do i find the text box control to drag onto the form? Visual Studio 2012 i'm using, any knowledge to let lose on me?
Ron MalmsteadInformation Services ManagerCommented:
Go to "View", Toolbox.
In the list you should see a textbox control listed.
Drag and drop it onto your form in design view.

Tip: ..double click the textbox control on your form, it will auto-generate an "OnChange" method in your code.  You can use this method to validate input on the textbox control, and it will fire everytime the text in the box changes.
SuperJinxAuthor Commented:
Thank you for your help.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.