Skip to Content
0
Former Member
Oct 18, 2004 at 01:50 PM

Calling Web Service AFTER db update

23 Views

I have set up some UI code that will call an outside web service that in turn uses the DI to access data that has been just changed on a form.

The way I am doing this is to register a handler for the PO window, that calls the web service when ever the update button is pressed. The web service in turn calls the DI, and gets all the lines from the purchase order and does something with the data.

The problem is, if I update the data that the webservice is using, the webservice is getting the OLD values for that data. (example, I update price from $40, to $45 and click the update button, and the webservice DI interface gets $40.)

Here is my IF statement to get into the code

If pVal.FormType = 142 And pVal.FormMode = fm_UPDATE_MODE And pVal.ItemUID = "1" And pVal.EventType = et_CLICK Then

and inside that code I do this final check separately:

If pVal.Before_Action = False Then

to make sure the 'work' has been done by SAP.

But, it still doesn't work. Also, the pVal.Action_Success

is NEVER true.

Should I be testing for a different event ?

ANY HELP would of course be appreciated.