Click here to Skip to main content
15,860,943 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: Data Reader only producing one row of records. Any ideas why? Pin
samflex10-May-19 4:39
samflex10-May-19 4:39 
GeneralRe: Data Reader only producing one row of records. Any ideas why? Pin
jkirkerx10-May-19 8:22
professionaljkirkerx10-May-19 8:22 
GeneralRe: Data Reader only producing one row of records. Any ideas why? Pin
samflex10-May-19 10:31
samflex10-May-19 10:31 
GeneralRe: Data Reader only producing one row of records. Any ideas why? Pin
jkirkerx12-May-19 13:15
professionaljkirkerx12-May-19 13:15 
GeneralRe: Data Reader only producing one row of records. Any ideas why? Pin
samflex16-May-19 14:39
samflex16-May-19 14:39 
Questionodata Pin
Member 140736591-May-19 2:33
Member 140736591-May-19 2:33 
AnswerRe: odata Pin
jkirkerx3-May-19 9:01
professionaljkirkerx3-May-19 9:01 
QuestionSOAP and using a Class containing two sub classes with same name problem Pin
Martin Stevens26-Apr-19 17:18
Martin Stevens26-Apr-19 17:18 
Hi
I have an existing class that sits in a library project that is used natively for handling data object instances and also serialized/deserialized for use with json, xml and datasets. Changing the class looks to be tricky without compromising other projects.

I'm trying to put a SOAP wrapper around some of the class logic but running into problems because the class has multiple Subclasses with the same name.

Error
Types 'Library.DataModel.HardwareOrder.ResponseSet' and 'Library.DataModel.ProduceOrder.ResponseSet' both use the XML type name, 'ResponseSet', from namespace 'http://MyTest.com/'. Use XML attributes to specify a unique XML name and/or namespace for the type.


This is my ASMX
VB
<WebMethod()>
    Public Function SubmitHardwareOrder(ByVal Parameters As DataModel.HardwareOrder.Parameters) As DataModel.HardwareOrder.ResponseSet
	'other code logic here
	End Function
	
	<WebMethod()>
    Public Function SubmitProduceOrder(ByVal Parameters As DataModel.ProduceOrder.Parameters) As DataModel.ProduceOrder.ResponseSet
	'other code logic here
	End Function


This is a small sample of my class
VB
Public Class DataModel

    Public Class HardwareOrder

        Public Class ResponseSet

            Public Property ResponseHeader As List(Of ResponseHeaderRow)

            Public Class ResponseHeaderRow

                Public Property TransactSucceed As Boolean
                Public Property TransactCode As String
                Public Property TransactDescription As String
                Public Property TransactionReference As String
                Public Property TpxID As String

            End Class

        End Class

    End Class

    Public Class ProduceOrder

        Public Class ResponseSet

            Public Property ResponseHeader As List(Of ResponseHeaderRow)

            Public Class ResponseHeaderRow

                Public Property TransactSucceed As Boolean
                Public Property TransactCode As String
                Public Property TransactDescription As String
                Public Property StaffID As String
                Public Property PurchaseOrder As String

            End Class

        End Class

    End Class

End Class


I've been looking for solutions but so far I haven't found anything that has enabled me to use my existing class without alteration.

Does anyone know of any tricks that can be done in the ASMX to make it work?

modified 26-Apr-19 23:38pm.

AnswerRe: SOAP and using a Class containing two sub classes with same name problem Pin
jkirkerx3-May-19 8:38
professionaljkirkerx3-May-19 8:38 
GeneralRe: SOAP and using a Class containing two sub classes with same name problem Pin
Martin Stevens10-May-19 20:03
Martin Stevens10-May-19 20:03 
GeneralRe: SOAP and using a Class containing two sub classes with same name problem Pin
jkirkerx12-May-19 13:03
professionaljkirkerx12-May-19 13:03 
Questionprint sql data from vb Pin
Member 1433060825-Apr-19 1:17
Member 1433060825-Apr-19 1:17 
AnswerRe: print sql data from vb Pin
Afzaal Ahmad Zeeshan25-Apr-19 1:36
professionalAfzaal Ahmad Zeeshan25-Apr-19 1:36 
QuestionSharing API's between multiple sites in IIS 8.5 Pin
Fred283424-Apr-19 21:39
Fred283424-Apr-19 21:39 
AnswerRe: Sharing API's between multiple sites in IIS 8.5 Pin
Richard Deeming25-Apr-19 1:17
mveRichard Deeming25-Apr-19 1:17 
GeneralRe: Sharing API's between multiple sites in IIS 8.5 Pin
Fred283425-Apr-19 1:47
Fred283425-Apr-19 1:47 
QuestionSo I finally got my Angular wrapped in .Net Core 2.2 app working in a Docker Container on a production server. Pin
jkirkerx16-Apr-19 11:14
professionaljkirkerx16-Apr-19 11:14 
SuggestionRe: So I finally got my Angular wrapped in .Net Core 2.2 app working in a Docker Container on a production server. Pin
Richard MacCutchan20-Apr-19 22:16
mveRichard MacCutchan20-Apr-19 22:16 
GeneralRe: So I finally got my Angular wrapped in .Net Core 2.2 app working in a Docker Container on a production server. Pin
jkirkerx21-Apr-19 8:17
professionaljkirkerx21-Apr-19 8:17 
Questionwithout using session and querty string value pass in another form Pin
UDTWS14-Apr-19 23:39
UDTWS14-Apr-19 23:39 
AnswerRe: without using session and querty string value pass in another form Pin
User 418025415-Apr-19 7:44
User 418025415-Apr-19 7:44 
QuestionExpiry date and Update Expiry Date Pin
Member 1370260513-Apr-19 1:49
Member 1370260513-Apr-19 1:49 
AnswerRe: Expiry date and Update Expiry Date Pin
User 418025415-Apr-19 7:55
User 418025415-Apr-19 7:55 
SuggestionRe: Expiry date and Update Expiry Date Pin
Richard Deeming15-Apr-19 8:25
mveRichard Deeming15-Apr-19 8:25 
AnswerRe: Expiry date and Update Expiry Date Pin
jkirkerx16-Apr-19 9:57
professionaljkirkerx16-Apr-19 9:57 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.