Link to home
Start Free TrialLog in
Avatar of eforkushe
eforkushe

asked on

Can't view .aspx file in browser.

When I only had the SDK installed, I could enter an aspx file in my browser address bar (http://localhost/file.aspx). and it would display correctly the file stored in my IIS wwwroot directory (C:\Inetpub\wwwroot\file.aspx).

Now that I have VS.NET installed, when I load the same file, I get a file save/open box, and then it opens up VS.NET and displays the code in the IDE.  Obviously, I can't correctly preview the page this way.

My IIS server appears to be working properly.  When I enter an asp file in the browser address bar, as opposed to an aspx, it functions properly.

I went into folder options to change the "open with" file from VS.NET to Internet Explorer, but that didn't work either.
ASKER CERTIFIED SOLUTION
Avatar of daveky
daveky

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 eforkushe
eforkushe

ASKER

Probably because I have XP, there were a couple of minor differences.  The file name was aspnet_regiis.exe, and of course the path was different.  And it didn't function properly until I restarted.  Thank you daveky.
Ahem, actually its always aspnet_regiis.exe. oops. Well done for working that out. :-)
I get the same problem, even after executing aspnet_regiis.exe.

There is a handler entry for ASPX, and when I point the browser to an ASPX file it appears to return a blank page.

Any suggestions?
A blank page could be right if there is nothing on the aspx page to process! What HTML source is being returned? Is there at least a label control on the page?
True. However, in this case, it should return a page with two text boxes and a button.

The same set of ASPX and CS files works on another machine.
So, the pages are syntax free but what does the source HTML returned look like? Is it *really* blank or full of unparsed <asp:xxx ...></asp:xxx> tags? It sounds like you are more advanced than this. What happens if you try to debug the page with breakpoints? The textboxes/button haven't got their visibility set to false?
Thanks very much for responding! {I meant to do that on the first response, sorry.}

When the page is browsed, it is indeed blank. An attempt to view the source on the page returns another blank window. :(

During my research last night, I saw references to the fact that ASP and other features were turned off by default and each feature requires "activation". I'm wondering now if ASPX is not "turned on"? How can I check?

Also, there were references to Security - IIS, Application & NTFS. Could these be a factor?

Lastly, I checked the subdir where the compiled .NET assemblies should appear, and only found a couple of XML files which had the ASPX and CS filenames(?)

I have XP, .NET Framework 1.0375(?), and IIS 5.1.

Since ASP is working, I think it might be a configuration issue. Maybe I'm not setting up the virtual directory correctly. Though I did try using the wwwroot directory with equal success.

Again, I'm much obliged to you for your time. :)