Show SAP Status bar while SAP is executing through a script

chrisinus

New Member
Joined
Apr 25, 2017
Messages
3
Hello,

I wrote a macro to automate the extraction of data from SAP using SAP GUI scripts. What I want to achieve now is to add a status bar in a form which shows the actual text on the SAP status bar while the report is being produced.

I know how to read the SAP status bar, but I just can't get to execute any operation while SAP is running. Is there any techniques to use to regain control of the code while the script is waiting for SAP to generate the report?

This is the line where my code waits : session.findById("wnd[0]").sendVKey 8

Thank you in advance for any suggestions.
 

Excel Facts

Excel Wisdom
Using a mouse in Excel is the work equivalent of wearing a lanyard when you first get to college
Hi chrisinus.

I wrote code to extract from SAP, but I found it much too difficult to keep on running the excel file.
Also it seems that when SAP runs a transaction it hogs the resources so even screen refresh is funny in the excel application.

Could you not just "mock" the SAP statusbar?
Let's say you loop through a list of materials, that you running a specific transaction to extract stock numbers, then you know the material name/number.
You could write out the material description from the loop to the excel statusbar.
 
Upvote 0
Hi chrisinus.

I wrote code to extract from SAP, but I found it much too difficult to keep on running the excel file.
Also it seems that when SAP runs a transaction it hogs the resources so even screen refresh is funny in the excel application.

Could you not just "mock" the SAP statusbar?
Let's say you loop through a list of materials, that you running a specific transaction to extract stock numbers, then you know the material name/number.
You could write out the material description from the loop to the excel statusbar.

Hi Szita2000,

Thanks for the reply.

That is an interesting workaround but it would make sense only while looping through a previously known number of items. In my case I don't know the outcome of the report (i.e. when extracting a list of open AR items).

I may have to estimate a running time and feed a progress bar according to the elapsed time. Maybe using a combination of DoEvents and OnTime methods...

It's always challenging to work between different systems. I like that :)
 
Upvote 0

Forum statistics

Threads
1,223,885
Messages
6,175,187
Members
452,616
Latest member
intern444

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top