aspnet_regiis.exe not a valid win32 application

I am following the instructions in “Build Your Own ASP.NET 2.0 Web Site Using C# & VB, 2nd Edition” and I hit wall on page 11 (yeah I know kinda early). On page 11, it says Type the following command to install ASP.NET: C:\Program Files\…\SDK\v2.0>aspnet_regiis.exe -i When I do it, I get: C:\Program Files\Microsoft.NET\SDK\v2.0\aspnet_regiis.exe is not a valid Win32 application. Pretty sure I followed the instructions to a T, so I’m not sure what went wrong.

Not sure … I always just use the ASP.NET tab in the IIS manager to configure which version of the .NET framework to run on each website.

You should be looking in %SYSTEMROOT%\Microsoft.NET\Framework\v2.0.50727\ not in the SDK . . . .

Good catch - I never even noticed that:
C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727

But what am I looking for in there?

In the book on page 11 it says to use the SDK command prompt:

After installing the .NET Framework and the SDK manually, you will need to configure IIS to make it aware of ASP.NET. To do this, you need to follow a few simple steps:
1.
Open the command prompt by selecting Start > All Programs > Microsoft .NET Frameworks SDK v2.0 > SDK Command Prompt.
2.
Type the following command to install ASP.NET:
C:\Program Files\…\SDK\v2.0>aspnet_regiis.exe -i

The funny thing is when I followed the exact same instructions on another computer with the same OS (XP Service Pack 2 ), it worked as the author described it would:

Start installing ASP.NET (2.0.50727).

Finished installing ASP.NET (2.0.50727).

Unfortunately I can’t use that PC on a regular basis. Anyways, still stumped here.:frowning:

It’s the same command, just use the new path:

  1. Open a command prompt - Start > Run > cmd

  2. Type this command in:
    C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\aspnet_regiis.exe -i

Replace “C:\WINDOWS” with whatever your system root is.

That seems to have worked! Thanks!