Jeffrey Palermo (.com)

Sponsors

The Lounge

News

Advertisement

Images in this post missing? We recently lost them in a site migration. We're working to restore these as you read this. Should you need an image in an emergency, please contact us at imagehelp@codebetter.com
.NET VB ASP.NET Bug

I normally write my ASP.NET apps with C#.  With my current project, I'm supporting extensions to it, so I decided to test them with extras written in other .Net languages: VB and J#.  I wrote one in J#, and it worked just fine.  I wrote one in VB, and it bombed with this error:

Compilation Error

Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: The compiler failed with error code 2000.


Show Detailed Compiler Output:

C:\WINDOWS\system32> "c:\windows\microsoft.net\framework\v1.1.4322\vbc.exe" /t:library . . .

Microsoft (R) Visual Basic .NET Compiler version 7.10.3052.4
for Microsoft (R) .NET Framework version 1.1.4322.573
Copyright (C) Microsoft Corporation 1987-2002. All rights reserved.

vbc : Fatal error BC2000 : compiler initialization failed unexpectedly: Cannot change thread 
mode after it is set. 

Upon further investigation, anything written in VB.Net running against ASP.NET produced this.  Even the simplest, nothing page with Language=”VB” produced this error.  Researching this problem on Google produced some others who have had this problem with Win XP and ASP.NET 1.1.  They resolved it by uninstalling and reinstalling IIS and then reregistering the aspnet_isapi.dll.  I have been hesitant to do this because of the possibility of having to reinstall VS.  Unlikely, but I don't have the setup files with me, so it would present a problem.  In 3 days I'll be back at home where I have the setup files, so I'm going to try it now so I can test out .Net Nuke (which is written with VB).  So, here I go *crossed fingers on my knees praying to God*. . .

Done!  It worked.  I can use VB.Net again!  I'm glad I backed up my IIS configuration because the reinstall cleared it, but a simple restore, and it's as if I never did anything.  .Net Nuke is up and running. 

This was a very curious problem indeed.  Why were VB pages the only ones affected?  Maybe we'll never know. . .  :)


Posted 04-18-2004 8:52 PM by Jeffrey Palermo

[Advertisement]

Comments

RL wrote re: .NET VB ASP.NET Bug
on 06-08-2004 12:35 AM
Thanks Dude!

bale wrote re: .NET VB ASP.NET Bug
on 06-09-2004 3:53 AM
It's not working for me Man... :(
Ng Kock Leong wrote re: .NET VB ASP.NET Bug
on 10-13-2004 4:59 PM
I also have the same problem. But i delete away some carriage returns on the source code and it returns.

After I add or modify my codes, it might return again.
Chad wrote re: .NET VB ASP.NET Bug
on 12-22-2004 3:40 AM
I have the same issue, but I close out of the solution and reopen it works for a couple of runs and then it bombs again. Close solution, reopen it works for another 2 or 3 runs and then bombs again. Only happens on certain ASP.net apps not all.

Any recommendations?
Sachin Pahwa wrote re: .NET VB ASP.NET Bug
on 02-17-2005 8:37 PM
Thanks Buddy you have been really a great help, as I was stuck up here for quite a few days.