SAP Tutorials Blog


 

 


TRY.

    DATA(tz) = cl_abap_context_info=>get_user_time_zone( ).

  CATCH cx_abap_context_info_error.

ENDTRY.


"Using XCO (the reference created without '->value' is used in some XCO method calls,

"as shown in some of the following code snippets)

"User's time zone

DATA(tz_w_xco) = xco_cp_time=>time_zone->user->value.

"UTC

DATA(tz_w_xco_utc) = xco_cp_time=>time_zone->utc->value.


Serkan AKKAVAK

Computer Engineer BSc

Head of SAP & Software Department

Contact : serkurumsal@yandex.com