views:

525

answers:

3

I've just recently upgraded to using Visual Studio express editions with service pack 1. Previously I was using the express editions minus the service pack. The IDE for C++ and C# run fine for me but when running the Visual Web Developer IDE I get a crash when trying to switch to design mode on any page I attempt it on.

I have been able to track down the particular line and module this crash is occurring in. Its from the file afxcrit.cpp from the DLL fpacutl.dll. The relevant function where the crash is occurring is as follows...

void AFXAPI AfxLockGlobals(int nLockType)
{
    ENSURE((UINT)nLockType < CRIT_MAX);

    // intialize global state, if necessary
    if (!_afxCriticalInit)
    {
     AfxCriticalInit();
     ASSERT(_afxCriticalInit);
    }

    // initialize specific resource if necessary
    if (!_afxLockInit[nLockType])
    {
     EnterCriticalSection(&_afxLockInitLock);
     if (!_afxLockInit[nLockType])
     {
      InitializeCriticalSection(&_afxResourceLock[nLockType]);
      VERIFY(++_afxLockInit[nLockType]);
     }
     LeaveCriticalSection(&_afxLockInitLock);
    }

    // lock specific resource
    EnterCriticalSection(&_afxResourceLock[nLockType]); // <--- CRASH HERE !!!
#ifdef _DEBUG
    ASSERT(++_afxResourceLocked[nLockType] > 0);
#endif
}

Any help/thoughts is greatly appreciated.

A: 

Is your installation customised in anyway? Do you have VS add-ins, etc. installed? If so, try removing them one by one and/or restore all app settings back to their defaults. I'm not so familiar with the express editions so I'm not sure what kind of customisations they support.

If all else fails, I hate to say it but...

1) make sure all your work is safely saved seperately from the application folders and/or is backed up

2) uninstall the app (if uninstall options are given, use the most complete one, e.g. delete all files, settings, preferences, etc.)

3) reboot

4) run CCleaner (both file deletion and registry fixer)

5) reboot

6) re-install

That is my tried and tested fall back method for when simply 'all else fails'. It usually works unless there is a genuine bug in the software.

AdamRalph
Nope. No customizations in anyway. No VS add-ins. Just the standard installation. Going to try out your suggestion of uninstalling, reboot and running CCleaner. Here's hoping. Thanks for the feedback and suggestions.
Rob Segal
ok, good luck! can you accept my answer if it works? ;-)
AdamRalph
+2  A: 

Well the computer has lost in the end as it always does! I found this thread to be a big help as there were a bunch of people posting with very similar issues to mine...

http://forums.asp.net/t/1186584.aspx?PageIndex=1

On the first page there is the following suggestion...

Make sure Microsoft Web Authoring Component appears in Control Panel. If it does, uninstall it. The go to WCU\WebToolsCore\en-us in VS DVD and run WebToolsCore.exe. The setup does not have UI, give it about 10 minutes to finish. Verify that Web Authoring Component appears in Control Panel. Try go to DV again.

I followed through with this suggestion and uninstalled the "Microsoft Web Authoring Component" however I couldn't find the "WebToolsCore" folder in the express installation disc as noted in the details. I did however find the folder "X:\VWDExpress\WCU\WebDesignerCore". Figuring this is pretty much the same thing I installed WebDesignerCore.EXE and *WebDesignerCore_KB945140.EXE* which are both in the the WebDesignerCore folder. Its a silent install so nothing looks immediately to have taken effect but when I headed into Visual Web Developer and switched to design mode success! It works!

Rob Segal
I had the same issue with Visual Studio 2008 Development Edition - http://forums.asp.net/p/1191630/2047898.aspx#2047898
Michael Kniskern
A: 

You don't actually have to remove the Microsoft Web Authoring Component. A simple repair from the add/remove programs dialog works just fine.

Terrah