I've installed VS2005 in WinXp SP2.

When i'm trying to run asp.net web application in my local machine i'm getting the following error:-

"Unable to connect to visual studio's localhost web server."

same type of thing is happening when i'm trying to open a windows form application. this time the error is :-

"The application is failed to initialize properly. Click on OK to terminate the application."

What is the cause and remedies for the above error?

Do you have XP Pro? - Home doesnt have IIS so theres some fiddling required. Also you must be logged in as an administrator and be a member of the Debuggers group and have opened the necessary ports in your firewall

Do you have XP Pro? - Home doesnt have IIS so theres some fiddling required. Also you must be logged in as an administrator and be a member of the Debuggers group and have opened the necessary ports in your firewall

VS ships with it's own web server so that developers can test their websites without having IIS installed on the local machine :icon_wink:

@choudhuryshouvi: since this happens for web apps and winforms apps, it almost sounds like your .NET runtime is messing up. Is it possible for you to post your web app, and I can try running it on my machine?

VS ships with it's own web server so that developers can test their websites without having IIS installed on the local machine

Oh right, i didnt know that. Maybe its a 2005+ thing because my copy of VS2003 doesnt work on Home for web development.

@choudhuryshouvi: since this happens for web apps and winforms apps, it almost sounds like your .NET runtime is messing up. Is it possible for you to post your web app, and I can try running it on my machine?

its a simple application which only has a textbox,a label and a button. the program is i'll write some text into the textbox and clicking the button will display the same as the label's text. for this i've written the following code:-(using my code behind page in vb.net)

on button_click()
if trim(textbox1.text)<>"" then
   label1.text=textbox1.text
   textbox1.text=""
   textbox1.focus
else
   msgbox("plz input some text.")
   textbox1.focus
endif

that's all. i was just testing my local web server whether its working or not but i couldn't.

i don't how will it help you in solving my prob. let's see what happens???

hm... I don't see any reason why that wouldn't work. As much as I hate the idea, have you tried uninstalling and reinstalling .NET and VS?

yes, i've already been advised that. though i know that this is the only option i've left but i was wondering whether there is any other way to solve this problem?

one thing i should tell you. before installing vs2005 i'd installed iis5.1. is that affecting? i mean to say is there any kind of version confliction problem occuring between IIS5.1 and VS2005's webdev.webserver.exe. i'm asking you because one of my office colleague has told me about that and also told me that i shouldn't install IIS on my local machine.

Could u plz tell me is that correct or not? because i've already searched microsoft knowledge base where microsoft said that both the IIS and VS2005's webserver can run in the same local machine.

Installing IIS should be fine. The VS webserver will allow to to run an ASP.NET website from your local machine, but only when you start it through VS. When you debug a website this way, VS fires up the webdev.webserver.exe and attaches the debugger to it.

If you wanted to host your website from a machine, you need IIS. To create this website, you would create an IIS hosted website in VS, work on it, and then hit run or debug. When you hit debug this way, VS attaches the debugger to IIS and IIS is what actually serves the site.

So, having IIS should not be a problem. And as unhelpful as it sounds, I can say that it "works on my machine."

Sounds well but not really helpful to me in case of solving my problem as it couldn't in my machine.

So what would be the summery?
What are you suggesting me to do? is there any way or i've to do the dirty work???

One more thing, is only uninstalling IIS can fix this problem? i'm not sure. asking for your suggestion.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.