C
cj2
Which function shows the proper way to return this structure
Validate, Validate2, or Validate3? And a short why would be nice.
Public Class Validate
Inherits System.Web.Services.WebService
Public Structure ValResult
Dim mResponse As String
Dim mReason As String
End Structure
<WebMethod()> _
Public Function Validate(ByVal ibtn As String, ByVal irequestor As
String)
Dim thisResult As New ValResult
thisResult.mResponse = "ALLOW"
thisResult.mReason = "Good"
Return thisResult
End Function
<WebMethod()> _
Public Function Validate2(ByVal ibtn As String, ByVal
irequestor As String) As ValResult
Validate2.mResponse = "ALLOW"
Validate2.mReason = "Good"
Return Validate2
End Function
<WebMethod()> _
Public Function Validate3(ByVal ibtn As String, ByVal irequestor As
String) As ValResult
Dim thisResult As New ValResult
thisResult.mResponse = "ALLOW"
thisResult.mReason = "Good"
Return thisResult
End Function
End Class
Validate, Validate2, or Validate3? And a short why would be nice.
Public Class Validate
Inherits System.Web.Services.WebService
Public Structure ValResult
Dim mResponse As String
Dim mReason As String
End Structure
<WebMethod()> _
Public Function Validate(ByVal ibtn As String, ByVal irequestor As
String)
Dim thisResult As New ValResult
thisResult.mResponse = "ALLOW"
thisResult.mReason = "Good"
Return thisResult
End Function
<WebMethod()> _
Public Function Validate2(ByVal ibtn As String, ByVal
irequestor As String) As ValResult
Validate2.mResponse = "ALLOW"
Validate2.mReason = "Good"
Return Validate2
End Function
<WebMethod()> _
Public Function Validate3(ByVal ibtn As String, ByVal irequestor As
String) As ValResult
Dim thisResult As New ValResult
thisResult.mResponse = "ALLOW"
thisResult.mReason = "Good"
Return thisResult
End Function
End Class