10-17-2006 11:29 AM
Hi,
in my ALV i´ve added a button to display the list with Adobe acrobat reader.
Most of the users access SAP throuh citrix but we developers access SAP locally.
depending on the user´s access to SAP the path to store the pdf must be C:list.pdf for local access or P:list-pdf for access throuh citrix.
How can i determine if a user has had access to SAP locally or via citrix in order to send the spool to C: or P: respectively?
Best regards.
10-17-2006 11:44 AM
Hi calsadillo,
try this code and you get the directory.
REPORT ZGRO_TEST.
*
DATA: SAPGUI_DIR TYPE STRING.
*
START-OF-SELECTION.
*
CALL METHOD CL_GUI_FRONTEND_SERVICES=>GET_SAPGUI_DIRECTORY
CHANGING
SAPGUI_DIRECTORY = SAPGUI_DIR.
*
CALL METHOD CL_GUI_CFW=>FLUSH.
*
IF SY-SUBRC <> 0.
WRITE: / 'ERROR'.
ELSE.
WRITE: / SAPGUI_DIR.
ENDIF.
*
END-OF-SELECTION.
Regards, Dieter
10-17-2006 11:44 AM
Hi calsadillo,
try this code and you get the directory.
REPORT ZGRO_TEST.
*
DATA: SAPGUI_DIR TYPE STRING.
*
START-OF-SELECTION.
*
CALL METHOD CL_GUI_FRONTEND_SERVICES=>GET_SAPGUI_DIRECTORY
CHANGING
SAPGUI_DIRECTORY = SAPGUI_DIR.
*
CALL METHOD CL_GUI_CFW=>FLUSH.
*
IF SY-SUBRC <> 0.
WRITE: / 'ERROR'.
ELSE.
WRITE: / SAPGUI_DIR.
ENDIF.
*
END-OF-SELECTION.
Regards, Dieter