Global.Micrsoft.VisualBasic.ApplicationsServices... is not defined error BC30002

Viewed 1430

I'm converting some old legacy VB apps from .NET framework to .NET 5, and have worked through most of the issues, however, I'm lost on these:

Error   BC30002 Type 'Global.Microsoft.VisualBasic.ApplicationServices.ApplicationBase' is not defined.
Error   BC30002 Type 'Global.Microsoft.VisualBasic.ApplicationServices.User' is not defined.
Error   BC30002 Type 'Global.Microsoft.VisualBasic.Devices.Computer' is not defined.
Error   BC30002 Type 'Global.Microsoft.VisualBasic.MyServices.Internal.ContextValue' is not defined.

VisualBasic 10.3.0 package is included in the project.

Any tips are appreciated.

Thanks, Bill

1 Answers

I came accross the same issue today trying to update a .net framework (4.6 but I guess it applies to 4.x generally) to .net 5 using Microsofts Upgrade assistent.

I found the solution in this bug report on github:

Simply put, add the following to your newly created .vbproj-file:

<PropertyGroup>
  <MyType>Empty</MyType>
</PropertyGroup>

Place at the end of of .vbproj-file just before </Project> end tag.

Related