We need to invoke a webservice method that will call an sp that may run
up to 1 hour so we want to start the sp then let the client continue
working. I have read about the OneWay:=true but calling the webservice
it seems to still wait until the service is finished before returning
to the client. Any ideas? - Code below..
In the webservice we define this method:
<SoapDocumentMethod(OneWay:=True), _
WebMethod(EnableSession:=True, Description:="STX processing of
imported invoices.")> _
Public Sub StartProcessingInvoices()
--code to run the sp which works as needed
End Sub
In the codebehind aspx page:
'Final call to webservice to start processing inported data
Dim wsInvoices As New STXProcessInvoices
Dim resultMessage As String
wsInvoices.StartProcessingInvoices()
...continue processing and displaying the aspx results page
to the client
Keith McDonald - 26 Jan 2006 20:13 GMT
This looks to be solved. We had the webservice in the same project as
the aspx page. Not sure what the difference is but putting it in as a
web reference and calling it that way fixed the problem.
m.posseth - 29 Jan 2006 08:54 GMT
I guess the difference is the threading mechanism used , in your code you
could have acomplished the same if you used a background worker
regards
Michel Posseth [MCP]
> This looks to be solved. We had the webservice in the same project as
> the aspx page. Not sure what the difference is but putting it in as a
> web reference and calling it that way fixed the problem.