GUI_GET_REGVALUE
GUI_SET_REGVALUE
ROOT:
O: HKEY_CLASSES_ROOT
1: HKEY_CURRENT_USER
2: HKEY_LOCAL_MACHINE
3: HKEY_USERS
注:对REG_DWORD类型的键值操作有问题
比较好的方法是用CL_GUI_FRONTEND_SERVICES:
REPORT z_barry_test NO STANDARD PAGE HEADING .
DATA: value TYPE i.
CALL METHOD cl_gui_frontend_services=>registry_get_dword_value
EXPORTING
root = cl_gui_frontend_services=>hkey_local_machine
key = 'SOFTWARE\IBM\ConfigUtil\InstallInfo'
value = 'TPCU'
IMPORTING
reg_value = value
EXCEPTIONS
cntl_error = 1
error_no_gui = 2
not_supported_by_gui = 3
OTHERS = 4.
CALL METHOD cl_gui_cfw=>flush.
WRITE value .
阅读(3708) | 评论(0) | 转发(0) |