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

How to find Operating System name dynamic using sap program.

vijay_sharma12
Explorer
0 Likes
2,544

Hi,

   Is there a way to find out the Operating system on which currently SAP is implemented dynamic through Program.

ex. windows, Linux.

thanks & regards,

vijay

1 ACCEPTED SOLUTION
Read only

Former Member
2,019

hi,

You can use System Fields sy-opsys to find the operating system on which sap is implemented .

Regards.

Jaydeep

5 REPLIES 5
Read only

Former Member
2,020

hi,

You can use System Fields sy-opsys to find the operating system on which sap is implemented .

Regards.

Jaydeep

Read only

0 Likes
2,019

Hi patel jaydeep,

   Thanks for your response , sy-opsys get the host name of the system. Is there any possibility for client system.

regards,

vijay

Read only

0 Likes
2,019

Please take a look at class CL_GUI_FRONTEND_SERVICES, method GET_PLATFORM.

http://help.sap.com/saphelp_nw73ehp1/helpdata/de/7e/ca034e332d4accb2d041fe81029aea/content.htm

Read only

vamsilakshman_pendurti
Active Participant
0 Likes
2,019

Hi

Use the method as bellow..

call method Cl_gui_frontend_services=>Get_user_name

----------------------------

----------------------------

And then use the method

  Call method cl_gui_cfw=>flush

The reason for using flush is ......see this link

http://help.sap.com/saphelp_nw04/helpdata/en/06/3fa1879f2811d2bd68080009b4534c/content.htm

Thanks,

vamsi.

Read only

Former Member
0 Likes
2,019

Hi,

function module SXPG_OPSYSTEM_GET_INT tells the OPSYS where SAP application server is running.

Method GET_PLATFORM of CL_GUI_FRONTEND_SERVICES tells you the OS where the SAP GUI is running.

Best regards,

Klaus