Link to home
Start Free TrialLog in
Avatar of prashanth ag
prashanth ag

asked on

How to Debug properly in c#.net using VS 2008

When I start debugging  a SMOSYS web application in C#  using Visual Studio 2008 , I get two files in the Debug folder apart from SMOSYS.exe file

1.SMOSYS.vshost.exe
2.SMOSYS.vshost.exe.manifest

and getting  error called

"Visual studio cannot start debugging becaz the  debug target 'e:\SMOSYS\bin\Debug\SMOSYS.exe'  is missing ,
build the project and retry or set the outpath and assembly name properties appropriately to point at the correct location for the target assembly"

Application need  only   .exe - the 'normal' executable not others how to achieve  ?
ASKER CERTIFIED SOLUTION
Avatar of Jacques Bourgeois (James Burger)
Jacques Bourgeois (James Burger)
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of prashanth ag
prashanth ag

ASKER

I run web appln with Clean Solution option, the error still persist  before that i have questions

1.How to add project (.sln) into existing asp.net website files  using MS VS 2008

2. while  creation of new  .sln file for web application(existing project) what output type i need select
from drop down (console appln , windows appln, class library )

plz explain me  in details
First of all, .sln is not a project, it is a solution. A project is .csproj.

For simple stuff, a solution contains only one project, but with more complex applications, a solution can contain many many projects.

A project is a website, or a windows application, or a class library (dll). A solution is a group of many projects. If you are working on a website that needs to use a dll, you put the 2 projects in the same solution, so that you can open their source code together and also debug them at the same time.

It looks as if you are a beginner, so you will have simple applications first. This means that for a while, you will be working with a solution that has only one project. The difference between both will thus be slim for you. But it is important to understand the difference in order to express yourself as precisely as possible.

---

1. You do not add a .sln to a website. The .sln is a list of all the projects that you need to develop on your web site. And each project is a list of everything that you need to work on a specific component of your application: source code, images, databases, etc. A solution is used only during development.

When you build your solution (through the build menu), the application itself is compiled. Compilation creates the web site in the directory specified in the properties of the main project.

---

2. Unfortunately, I do not have 2008 installed anymore. And since you seem to be starting, I would work VS 2013 instead of 2008. 2008 is 7 years old, and it is a long time in computing. VS 2013 can be downloaded for free from the Microsoft web site. My instructions are for 2013, there might be slight differences in 2008.

To create a web application, you go:

File...
New...
Project...
Templates...
Visual C# (because you are using C#)...
Web...
ASP.NET Web Application
Hi  James Burger,
thanks
i found other solutions from google (article posted  by Steve .c)
how to Create an .sln file for an existing ASP.NET application

"File ==> New ==> Project..."
 under "Other Project Types" choose "Visual Studio
Solutions" and create a blank solution.
Then from the Visual Studio menu choose "File ==> Add ==> Existing Web Site" and
point it to your web site to add it to your new solution
That other solution you found is to add a web site that already exists to a solution. It's not a way to create a new web site.