Robert McLaws: FunWithCoding.NET

Public Shared Function BrainDump(ByVal dotNet As String) As [Value]

News

<script type="text/javascript"><!-- google_ad_client = "pub-4330602465258980"; google_hints = "ASP.NET, VB.NET, C#, C#.NET, WindowsForms, .NET Framework, VS2005, Visual Studio, XAML, WinFX, Windows Workflow, WPF, WCF, Atlas, NetFX3, Visual Studio Orcas"; google_ad_width = 120; google_ad_height = 240; google_ad_format = "120x240_as"; google_ad_type = "text_image"; google_ad_channel ="4997399242"; google_color_border = "B6C9E7"; google_color_bg = "EFEFEF"; google_color_link = "0000FF"; google_color_text = "000000"; google_color_url = "002C99"; //--></script> <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script>
<!--
-->

You should feel free to challenge me, disagree with me, or tell me I'm completely nuts in the comments section of each blog entry, but I reserve the right to delete any comment for any reason whatsoever. That said, I will most likely only delete abusive, profane, rude, or annonymous comments, so keep it polite, please.

Blogroll

Cool .NET Articles

My .NET Tools

My Builder.com Articles

My MSKB Articles

Run the ASP.NET 2.0 Development Server From Any Folder

As I blogged about yesterday, I came up with a way to start up the web server that comes with Visual Studio 2005 by right-clicking on the folder you want to serve. Chris Frazier left some great feedback, along with Daniel Fisher.

I think I've solved all the problems that were involved, and there were a few. Besides what I initially talked about, Chris' wrapper solution didn't use the proper virtual path, due to an error in spacing. Daniel's solution went the StringBuilder route for setting up the executable's arguments, which took too much memory. I went the String.Format route, which accomplished the same thing with a lot less code.

I put together an installer that checks for the existence of the webserver executable, copies the wrapper to the .NET runtime directory, and adds the proper registry keys for both Admins and Non-Admins. I've tested it, and it does exactly what I need it to do. Let me know if anyone runs into any problems.

Comments

Clift Norris said:

Could you post the source for the project that produced the .MSI package?
# November 8, 2005 1:14 PM