HTTPUtils - Multiple Calls

robh

Member
Licensed User
Longtime User
Using the excellent httputils library I have succesfully got my app exchanging data via a SOAP asmx web service.

I am however struggling with the following code, whereby I am calling 2 subs, both of which call a webservice and bind returned data to the screen views:

Activity.LoadLayout("frmProductSearch")

HttpUtils.CallbackActivity="actProductSearch"
HttpUtils.CallbackJobDoneSub="JobDone"
HttpUtils.CallbackUrlDoneSub="UrlDone"


' bind brands
BindBrands

' bind the product categories
BindCategories

Everything runs fine when running each sub individually, however, when attempting to call the 2nd sub immediately after the 1st, I can step through and see that the httputils returns no data due to it still working on the request from the first sub.

Can anybody advise on the best way to overcome this issue?

Many thanks in advance.
 

robh

Member
Licensed User
Longtime User
Thanks for the swift reply Erel.
So there is no way to do this? This seems like a big limitation of this util especially as some of my views call up to 6-7 existing webservices which I have no control over.

The only way I can think of doing this at present is to run subsequent jobs on JobDone events however, with the different combinations of calls that are possbible within my activity this is going to be very messy.

For example, I may want to call:

WebserviceMethod.A
WebserviceMethod.D
WebserviceMethod.E


and other occasions(depending on the user's on screen preferences at the time):

WebserviceMethod.C
WebserviceMethod.A
WebserviceMethod.B
WebserviceMethod.E


I understand you say I that the httputils does not currently support multiple calls but have you any pointers on how to implement an easy work around so I can make those type of ' chained'calls?

Thanks again.
 
Upvote 0
Top