Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Scheduling a program to run in foreground

Former Member
0 Likes
2,546

Hi all

is there any way of Scheduling a program to run in foreground.

My problem is that i am using gui_download and as far as I know i does not work with background.

Thanks

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,649

Hi,

It does seem possible to download data to the presentation server in the background mode using DATASET statements instead of gui_download. Have a look at this blog.

[http://www.sdn.sap.com/irj/scn/weblogs;jsessionid=(J2EE3417800)ID0139021250DB00478950859084604266End?blog=/pub/wlg/6830]

Regards,

Vikranth

10 REPLIES 10
Read only

SuhaSaha
Product and Topic Expert
Product and Topic Expert
0 Likes
1,649

>

> is there any way of Scheduling a program to run in foreground.

> My problem is that i am using gui_download and as far as I know i does not work with background.

Hello,

The eternal problem of GUI functions not working in background.

BTW, no way of solving this. For BG mode you have to use Application Server files.

Good luck !!!

Suhas

Read only

Former Member
0 Likes
1,649

Hello,

there can be 2-3 options for this problem....

1. You create a logical path and place all your files on application file server.... then you can schedule job...it will pick the file specified by logical file path...

2. Change the program in such a way that it triggers the child job... and import and export parameters with two program... for details you can ask..... by Job open, submit comman, job close.... and all commands you can create child jobs.

I think the filrst option is better to upload files on application file server and provide the logical path in the selection screen of your program

Thanks

manish

Read only

Former Member
0 Likes
1,650

Hi,

It does seem possible to download data to the presentation server in the background mode using DATASET statements instead of gui_download. Have a look at this blog.

[http://www.sdn.sap.com/irj/scn/weblogs;jsessionid=(J2EE3417800)ID0139021250DB00478950859084604266End?blog=/pub/wlg/6830]

Regards,

Vikranth

Read only

0 Likes
1,649

Hi Vikranth

Can we do the same if sap is running in Linux server

Thanks.

Read only

0 Likes
1,649

Hello Mader,

I am not sure of that since my system runs on windows os. Check if there is any option to map a shared network drive as mentioned in the blog for linux. I am sure it must be there. Just explore a bit and try your luck.

Regards,

Vikranth

Read only

SuhaSaha
Product and Topic Expert
Product and Topic Expert
0 Likes
1,649

Hello,

If you checked the blog carefully, you will find that for Unix or Linux OS the method mentioned wont work.

If you want to check, please check this [presentation|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/9831750a-0801-0010-1d9e-f8c64efb2bd2]

Hope this helps.

BR,

Suhas

Read only

0 Likes
1,649

Hi Suhas

Do you know how to loctae the folder RFCSDK (according to your suggested blog )in windows vista

Thanks.

Read only

0 Likes
1,649

for RFCSDK, see [Note 545784 - FAQ: RFC-related software: qRFC version, SAProuter, NIPING, RFC library see note 413708, RFC SDK, LGTST|http://service.sap.com/sap/support/notes/545784]

Read only

Clemenss
Active Contributor
0 Likes
1,649

Hi Malu,

You can us CL_GUI_TIMER object to create a process that will wait for a specified time. If you create a handler for its EVENT FINISHED (Timer Expired) and let this handler do your GUI_UPLOAD, this is possible.

You must avoid to get kicked out of the system for too much idle time. To avoid this, you can start the timer for a short period and before the desired time has been reached let the handler call CL_GUI_CFW=>SET_NEW_OK_CODE to trigger a PAI and start the timer again. So the system will never think you are idle

And your PC must be running with SAP system connected.

This is not elegant at all but a working solution. Why don't you put the files on a directory visible to SAP server, use OPEN/READ DATASET and do it in scheduuled background job.

Regards,

Clemens

Read only

Former Member
0 Likes
1,649

Thank you all

soleved with open dataset , visible to SAP.

regrads.