cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Stop Xacute-query on Web Page

Former Member
0 Likes
541

Greetings!

I have created a web page to work with MII transactions via browser. One of web page components is iCommand applet which invokes transaction. Applet is using Xacute-query. "OnClick" event, generated by special button, starts the query.

There I have faced a problem: while the query is running any other actions on web page can not be executed. In most cases this sutuation is good, but sometimes the query must be stopped manually, for example if input data is incorrect.

Question: what event or function should I use to stop Xacute-query from a web page?

Thank you!

Best Regards,

Vitaliy

View Entire Topic
Former Member
0 Likes

Hello Vitaly, there is already quite a fair bit on asynchronous call to transaction:

http://scn.sap.com/message/8097641

though you can not stop it if you are using the aynchronous message service, the user will not be impacted.

Another method is also to call the transaction through an XMLHttpRequest.

You can do this call and call the transaction to be executed asynchronously by MII, after returning an ID which will enable you to track the transaction and also to stop it.

In order to do so you will have to do the following:

1. Run the transaction by calling the following URL, This returns a transaction ID that you can reuse in the URL after:
/XMII/Runner?Transaction=<MY-FOLDER>/LongRunningTransaction&IsAsync=true&LogType=Info

2. You can use the following URL which will give you details on the current Status of the Transaction
/XMII/Illuminator?Service=BLSManager&Mode=Details&ID=<ID Returned by the previous call>

3. Then you call this URL in order to Terminate the transaction:
/XMII/Illuminator?Service=BLSManager&Mode=Terminate&ID

=<ID Returned by the previous call>

For information on how to call url directly in Javascript look at the following website:

http://www.w3schools.com/xml/xml_dom.asp

Cheers,

Arnaud

Former Member
0 Likes

Hello Arnaud!

Thank you a lot for your reply, it is very helpful! With the help of your approach I have successfuly run transaction via browser.

But can you please clerify the following: what is transaction ID and how can I get it to execute points 2 and 3 from your post?

Thank you for your time!

Regards,

Vitaliy

Former Member
0 Likes

Hello Vitaliy, if you look at the xml returned when you run the transaction through the url, you will see an XML attribute named transaction ID. This is the unique identifyer of your transaction.

You can then use this id in the subsequent urls.

Regards,

Arnaud