views:

306

answers:

2

I'd like to include the ASP.net Web Admin tool in a web site when a user logs in as an local manager of the web site, this will be on the LAN and not public.

I can obtain the link in Visual Studio ie

http://localhost:54397/asp.netwebadminfiles/default.aspx?applicationPhysicalPath=D:\DATA\Projects\WebIV\WebSite\&applicationUrl=/WebSite

However this changes from server to server and the physical path will change

is there a way to launch it via a relative link? or some other way to get its URL at run time?

http://msdn.microsoft.com/en-us/library/yy40ytx0%28VS.85%29.aspx

+2  A: 

First of all, I wouldn't recommend doing that.

It would be much better for you to write our own tool that exposes the functionality that you need.

However, if you really want to, copy all of the files in C:\Windows\Microsoft.NET\Framework\v2.0.50727\ASP.NETWebAdminFiles (or Framework64 on x64) to a separate Application on your website, then modify Web.config, etc to include security. I would also recommend that you delete all of the features that your managers don't need, and perhaps add logging. You'll also need to rewrite App_Code\WebAdminPage.cs, and perhaps some other files, to work with your web site.

SLaks
A: 

You could use a small implementation like: http://websitemanager.codeplex.com (if your site is in ASP.Net MVC), or just copy out the netwebadmin files to your project & deploy the application.

Hope that help,

Sunny Chaganty

Sunny