From the course: Visual Basic Essential Training

Create Console project in Visual Studio - Visual Basic Tutorial

From the course: Visual Basic Essential Training

Start my 1-month free trial

Create Console project in Visual Studio

- [Instructor] Real applications are comprised of many individual code files. To make it easy to load an applications' code and settings, Visual Studio uses a project based approach. Each project has an important master file, the project file, that contains a list of information about the project. What files to load, what are its code dependencies, and a lot more. For a VB project, this is called the VB proj file. You'll see it once we've created the project. To create a project in Visual Studio, go to file, new project, then pick the language you want, and the project type. In our case, it'll be console. There are three choices here. The top two are the only two that are important for us. First is a console application using the classic .NET framework. Second is a console application using the newer .NET Core. .NET Core is interesting because, if I create a console app here, it can run on a Windows and on Linux and Mac OS. For this example, we'll choose the first item on the list, and then click on next. On this screen, we configure our project. The project name will become the name of our VB proj file. So we'll call this one SimpleConsole. This will also make some other changes in our project. Now down here you'll see there's also a solution name. This is one area that confuses programmers who are new to Visual Studio. I'm creating a project, but Visual Studio always creates another item called a solution. Solutions are important once you need to work with multiple projects within Visual Studio. We get one, even though we only have one project now. Stick with me in the chapter, and we'll add more. I also get to pick the framework version down here, whether I want the solution file, which is an SLN extension file, and the VB proj file in the same directory. I don't want that. And the location. So I'm using the folder I created earlier in the course, called Vb Temp. Here it is. I moved the code from the first chapter, the one where I created it without using Visual Studio, into this folder called FirstAppWithoutVs. Select this folder, everything looks good. Click on the create button. That's it. We now have a new project. Let's verify that. I've opened up file explorer to the Vb Temp folder, and there's this new folder, SimpleConsole, and that contains the SLN file, that's the solution file, a sub folder called SimpleConsole, and within that is the VB proj file and some other files. Let's explore those in the next video.

Contents