Starting Projects
Learn about starting and configuring multiple projects in Visual Studio 2022 and testing a web service and an MVC client website concurrently.
Up to this point, we have only started one project at a time. Now, we have two projects that need to be started, a web service and an MVC client website. In the step-by-step instructions, we will start individual projects one at a time, but we should use whatever technique we prefer to start them.
Using Visual Studio 2022
Visual Studio 2022 can start multiple projects manually one by one if the debugger is not attached, as described in the following steps:
Step 1: Set the “Startup Project” for the solution as the Current selection.
Step 2: Select a project in Solution Explorer so its name becomes bold.
Step 3: Navigate to “Debug | Start Without Debugging” or press the “Ctrl + F5” key.
Step 4: Repeat steps 2 and 3 for as many projects as needed.
If it is needed to debug the projects, then multiple instances of Visual Studio 2022 must start. Each instance can start a single project with debugging.
Configuring multiple projects
We can also configure multiple projects to start up at the same time using the following steps:
Step 1: In Solution Explorer, right-click the solution and then select “Set Startup Projects…” or select the solution and navigate to “Project | Set Startup Projects…”
Step 2: In the Solution ‘<name>
’ Property Pages dialog box, select Multiple startup projects, and for any projects that we want to start, select either Start or Start without debugging, as shown in the figure:
Get hands-on with 1400+ tech skills courses.