SyntaxHighlighter

Showing posts with label Visual Studio. Show all posts
Showing posts with label Visual Studio. Show all posts

Friday, October 23, 2009

An error occurred while reading the app.config file

I edited my app.config file manually, which did not seem to agree with VS. Even though the XML was valid, I received the message: An error occurred while reading the app.config file. The file might be corrupted or contain invalid XML. Despite this message the code will still run, but its just annoying.

This is a known bug, which I managed to get rid off by removing the project from the solution, restarting Visual Studio and adding the project again.

Tuesday, July 8, 2008

Visual Studio editor annoyances

I have the nasty habit of copying code and then accidentally hitting Crtl+C again without selecting any text. VS clears your current clipboard item and replaces it with the line you're on.

I find this quite annoying, but luckily there's a way to get the previous items in the clipboard back. Just keep hitting Ctrl+Shitf+V to cycle through all the previous items.

Sunday, June 29, 2008

More issues moving over to new system

Ok so I don't have this dll on my system.

Could not load file or assembly 'System.Web.Extensions, Version=1.0.61025.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.

Just download and install the ASP.NET 2.0 AJAX Extensions package. Problems solved!

Vista administrator woes

Ok if you're a Vista user you're undoubtely also sick and tired of being bombarded with security pop-ups, which are aimed at keeping the average user from destroying the system with malware.

So you want to be a real administor? Follow these steps:
First, turn off UAC warnings.
1. Go into Control Panel.
2. Open up User Accounts (in classic view) and User Accounts and Family Safety -> User Accounts (in standard view).
3. Click Turn User Account Control on or off and follow the rest of the instructions.

Ok now you got rid of most of the issues, but Vista still with give you a hard time with Services and applications such as SQL Server and Visual Studio. It still won't think you are a full blown administrator and prompt you with the odd warning. Quite annoying.

Finally, Turn off "Run all administrators in Admin Approval Mode"
1. Open a run window, and type in secpol.msc and hit enter.
2. Expans Local Policies -> Security Options.
3. Scroll down to User Account Control: Run all administrators in Admin Approval Mode and disable the damned thing.
4. Restart and all should be well.

Visual Studio 2005 and IIS 7: Unable to open the Web

I recently upgraded to a new workstation, which came with Vista Ultra SP1. I tried to open my previous web apps and got this message:

"Unable to open the Web 'http://localhost/...'. The Web server does not appear to have the FrontPage server extensions installed."

A quick google search came up with this article on the MS Knoweldge Base:
http://support.microsoft.com/kb/936857

I followed the instructions and enabled the IIS Metabase and IIS 6 configuration compatibility component. I went back into VS Studio, clicked Reload Project, but no luck.

Next I went into IIS 7's management console. I noticed that the web apps were not added to an application pool yet. Just right-click the folder and choose Convert to Application. Reloaded the project again, and nothing...

Trying to solve the issue, I got a bit side-tracked and sorted out some annoying administrator issues.

I rebooted my system and my web app is working!! Whoop whoop!