Upgrade from VS2010 vb.net project to VS 2013 project Update 4 in dotnet 4 causing problems with service references

I have a WCF service library built into Visual Studio 2010 targeting DotNet 4.0.

This WCF service references an external service using service references to force the Windows service to do something when needed. All links were created using the Visual Studio 2010 development environment.

The service reference is defined as MyService.Interface, and this is how everything refers to it in the code.

It all works great and no problem.

Just installed a copy of Visual Studio 2013 Update 4 on the VM and imported a copy of the project.

Now all the references to my services for this windows service in the file generated by the reference.vb code are declared as global.MyService.Interface, not just MyService.Interface.

Now I have hundreds of errors indicating the type global.MyService.Interface is not defined.

If I delete the root namespace of a WCF project, this error is removed, but the solution will carry over to hundreds of other errors caused by deleting the namespace.

I am wondering what was added in VS2013 to make all service references global. added to these in the generated code (reference.vb) and is there a way to make it work the way it was used so that the code generation doesn't include the global. at the beginning of each link?

I tried to set the namespace for the service reference in reference.svcmap, but it made no difference.

I haven't tried svcutil yet as I don't want to go down the path of manually creating stuff that has worked for years because VS2013 is now doing something different and there will be other developers managing this and I don't want to have different update methods service references than they are used only because of the version change in Visual Studio.

I did some searches and found many cases where people had to add globals. to their links, but in this case the opposite is the case - it was automatically added and I want to remove it from the generated code but can't find where to do it. I hope there is a checkbox that I can uncheck and it magically revert back to how it works.

Any help is greatly appreciated.

  • SAMPLE * Code from a project opened in VS 2013 UPDATE 3. This code is generated as it has always been ...

<System.Diagnostics.DebuggerStepThroughAttribute(),  _
     System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")>  _
    Partial Public Class ExternalInterfaceServiceClient
        Inherits System.ServiceModel.ClientBase(Of BOHInterface.IExternalInterfaceService)
        Implements BOHInterface.IExternalInterfaceService
      

Run codeHide result


Code generated for the same project in VS 2013 Update 4. The Global keyword has been added to the beginning of every link in BOHInterface.IExternalinterface.

    
    <System.Diagnostics.DebuggerStepThroughAttribute(),  _
     System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "4.0.0.0")>  _
    Partial Public Class ExternalInterfaceServiceClient
        Inherits System.ServiceModel.ClientBase(Of Global.BOHInterface.IExternalInterfaceService)
        Implements Global.BOHInterface.IExternalInterfaceService
        
      

Run codeHide result


The second one breaks everything and its generated code into reference.vb.

Any way to get the code in VS2013 Update 4 to build the same as VS2013 Update 3?

BTW I'm using VS2013 Update 3 until this is sorted :)

Hello

Rod.

+3


source to share


1 answer


I had the same problem before build 10041 of Windows 10. Try updating Windows 10 to build 10041. I am also using Visual Studio 2013 Update 5 CTP 3.



0


source







All Articles