Calling Webmethod while another web method is in progress.

P

pinky

Hi all,

I am having one problem in web method.

I am calling one web method through windows application which is doing
some heavy processing.

while this web method is in progress i want to provide cacnel facility
through windows application.

So what i am doing is writing one property in web service for setting
cancel.

And in first web method i am continusously checking value of this
cancel variable.

but this is not working.

Can some one tell me what is wrong in it.

Or please suggest me some other alternative.

Thanks in advnace.
 
C

CaffieneRush

Web services are by default stateless.
You can persist your cancel variable in Session state (making sure you
first enable session state on your web methods) or persist state in
some other method.
 
P

pinky

Hi,

thanks for your reply.

i am using session variable for storing cancel flag.

but my problem is webmethod in which i am setting session variable
cancel to true is getting executed only after first one has compelted
which i don't want.

I tried with asynchronosly calling web method but of no luck.

Can you tell me how to provide cancellation through session variable as
using session variable is not working in my case.

Please help me asap.

thanks in advance.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,767
Messages
2,569,570
Members
45,045
Latest member
DRCM

Latest Threads

Top