‎2010 Feb 16 11:48 AM
I just capture the file path using fm f4_filename into one filed , then i displayed file path in a report. my requirement is when ever i click on that particular file path ,need to open that file and show . is there any option to open file path .
‎2010 Feb 16 11:59 AM
yes u can raju,
in at user command event, write the following code..
path = <from f4_filename fm>.CALL METHOD cl_gui_frontend_services=>execute
EXPORTING
document = PATH " take it as type string
minimized = 'X' " dont pass anything if u dont want to minimize it..
.
Regards,
Sumit
Edited by: Sumit Nene on Feb 16, 2010 1:08 PM
‎2010 Feb 16 11:52 AM
If you want to directly open a particular file from the presentation server, you could pass the file path to the method
cl_gui_frontend_services=>execute
‎2010 Feb 16 11:53 AM
‎2010 Feb 16 11:59 AM
my requirement is open that particular file and show . is there any solution for this.
‎2010 Feb 16 11:59 AM
yes u can raju,
in at user command event, write the following code..
path = <from f4_filename fm>.CALL METHOD cl_gui_frontend_services=>execute
EXPORTING
document = PATH " take it as type string
minimized = 'X' " dont pass anything if u dont want to minimize it..
.
Regards,
Sumit
Edited by: Sumit Nene on Feb 16, 2010 1:08 PM
‎2010 Feb 16 3:21 PM
‎2010 Feb 17 5:29 AM
thank you to
Erik Peterson, Sumit Nene and all . my problem was solved.thank you
‎2010 Feb 17 9:10 AM
Hi to all
my file is on application server . how can i open that particular file .I used CL_GUI_FRONTEND_SERVICES=>EXECUTE, hopefully it is for presentation server . just give some idea about application server file. thank you.
‎2010 Feb 16 12:12 PM
‎2010 Feb 16 2:41 PM
Hi ,
You can use the class CL_GUI_FRONTEND_SERVICES=>FILE_open_DIALOG to open that file but here again you need to split the file path into different variable as per your req.
‎2010 Feb 18 6:44 AM
hi raju, perhaps you should have cleared this at the start.
you cant directly execute a file of AS on PS.
what you can do is--
read file on AS using
OPEN DATASET FNAME FOR OUTPUT IN TEXT MODE ENCODING DEFAULT "" path on application server. write "output mode" for writing data into filethen use GUI_DOWNLOAD to save it on your PS.
finally you use the solution in previous posts to execute the same file.
this would not work for all kinds of file types i am afraid.
Sumit