Link to home
Start Free TrialLog in
Avatar of Darkkane78
Darkkane78Flag for Canada

asked on

WSDL.exe and VB.NET Case insensitive / Duplicate name

Hi,
When I used the tool WSDL.exe and i take VB.NET language, I have a little problem with duplicate name.
I've got the error ID:BC30663  Attribute 'GeneratedCodeAttribute' cannot be applied multiple times.
MSDN suggest to add Attribute Usage with the option AllowMultiple at true, but the error still here.

Any suggestion?

Here a part of the generated code...
<System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42"), _
 System.SerializableAttribute(), _
 System.Diagnostics.DebuggerStepThroughAttribute(), _
 System.ComponentModel.DesignerCategoryAttribute("code"), _
 System.Xml.Serialization.XmlTypeAttribute(AnonymousType:=True, [Namespace]:="http://xxx.com")> _
Partial Public Class GetAccountInformationResponse
    Private getAccountInformationResponseField As GetAccountInformationResponse
...
End Class


<System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42"), _
 System.SerializableAttribute(), _
 System.Diagnostics.DebuggerStepThroughAttribute(), _
 System.ComponentModel.DesignerCategoryAttribute("code"), _
 System.Xml.Serialization.XmlTypeAttribute(AnonymousType:=True, [Namespace]:="AccountProductOperations/BankAccountManagement/2-0")> _
Partial Public Class getAccountInformationResponse
Avatar of Bob Learned
Bob Learned
Flag of United States of America image

What is the difference between the two?  I imagine that this is coming from a C# web service.   If they are two separate methods, and you are accessing them from VB.NET, then I would change the name of one of them.

Bob
Avatar of Darkkane78

ASKER

The difference between the 2 partial class is
GetAccountInformationResponse
getAccountInformationResponse

The first letter is uppercase for the first one and lowercase the second.I have tried before post this error to change the second class with a different name, but I not sure that'll cause problem when I'll call the web service.
ASKER CERTIFIED SOLUTION
Avatar of Bob Learned
Bob Learned
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial