2007 Jan 18 4:50 AM
when recording using Tcode-SHDB for Transaction QS41 to create code group and codeone of the screen is missing.
After selecting the codegroup for creating codes i have to doubleclick on the tree which is visible on lefthand side.
But this is not visible while recording.
Any suggestion on this how to record.
Thanks in Advance
when recording using Tcode-SHDB for Transaction QS41 to create code group and codeone of the screen is missing.
After selecting the codegroup for creating codes i have to doubleclick on the tree which is visible on lefthand side.
But this is not visible while recording.
Any suggestion on this how to record.
Thanks in Advance
2007 Jan 18 5:05 AM
Hi Anitha,
Not all SAP screens support BDC..
I think in this case you can use BAPI...
Just check these BAPIs :
BAPI_QPGR_SAVEREPLICA
BAPI_QPGR_REPLICATE
Regards,
Hendy
2007 Jan 18 7:52 AM
BAPI BAPI_QPGR_SAVEREPLICA works only when i directly pass values to the structure fields. when i use internal table workarea to populate values into the BAPI structure fields its not working properly.
its displaying only the code n code groups in F4 help on field code group in tcode-QS41.
but its not displaying codes inside the transaction.
Please suggest regarding this
2007 Jan 18 9:08 AM
Hi Anitha,
BAPI_QPGR_SAVEREPLICA performs various checks on the code group to be saved.
If there are no errors, the code group, its codes, and the short and long texts are saved in the target system.
You have to pass values of your internal tables for the following tables:
Code group
CODE_GRP_SHORTTEXTTAB STRUCTURE BAPIQPGR_QPGT
CODE_GRP_LONGTEXTTAB STRUCTURE BAPIQPGR_GRP_LTXT
Codes
CODES_OF_CODE_GRP STRUCTURE BAPIQPGR_QPCD
Code inside the transaction
CODE_SHORTTEXTTAB STRUCTURE BAPIQPGR_QPCT
CODE_LONGTEXTTAB STRUCTURE BAPIQPGR_CD_LTXT
Regards,
Hendy
2007 Jan 18 11:20 AM
Hendy,
this is my code which i tested with one code group with one code.
but its not creating code but its creating code.
types:begin of ty_src,
cat_type like bapiqpgr_qpgr-cat_type,
code_group like bapiqpgr_qpgr-code_group,
short_text like bapiqpgr_qpgt-short_text,
code like bapiqpgr_qpcd-code,
st like bapiqpgr_qpct-short_text,
end of ty_src.
data int_src type table of ty_src.
data wa_src type ty_src.
data: ws_filename type string.
data: gt_bapiqpgr_qpgr type bapiqpgr_qpgr occurs 0 with header line,
gt_bapiqpgr_qpgt type bapiqpgr_qpgt occurs 0 with header line,
gt_bapiqpgr_qpcd type bapiqpgr_qpcd occurs 0 with header line,
gt_bapiqpgr_qpct type bapiqpgr_qpct occurs 0 with header line,
gt_bapiret2 type bapiret2 occurs 0 with header line.
constants:
lit_fty(10) type c value 'ASC',
lit_sep(1) type c value 'X'.
selection-screen begin of block a1 with frame title text-001.
parameters: p_fn like rlgrap-filename.
selection-screen end of block a1.
at selection-screen on value-request for p_fn.
perform get_filename using 'P_FN'
changing p_fn.
start-of-selection.
perform upload_file.
loop at int_src into wa_src.
clear:gt_bapiqpgr_qpgr,gt_bapiqpgr_qpgt.
clear:gt_bapiqpgr_qpcd,gt_bapiqpgr_qpct.
gt_bapiqpgr_qpgr-function = '004'.
gt_bapiqpgr_qpgr-cat_type = wa_src-cat_type.
gt_bapiqpgr_qpgr-code_group = wa_src-code_group.
gt_bapiqpgr_qpgr-status = '2'.
append gt_bapiqpgr_qpgr.
gt_bapiqpgr_qpgt-langu = 'EN'.
gt_bapiqpgr_qpgt-short_text = wa_src-short_text.
append gt_bapiqpgr_qpgt.
gt_bapiqpgr_qpcd-code = wa_src-code.
append gt_bapiqpgr_qpcd.
gt_bapiqpgr_qpct-code = wa_src-code.
gt_bapiqpgr_qpct-langu = 'EN'.
gt_bapiqpgr_qpct-short_text = wa_src-st.
append gt_bapiqpgr_qpct.
call function 'BAPI_QPGR_SAVEREPLICA'
exporting
i_code_group = gt_bapiqpgr_qpgr
tables
code_grp_shorttexttab = gt_bapiqpgr_qpgt
codes_of_code_grp = gt_bapiqpgr_qpcd
code_shorttexttab = gt_bapiqpgr_qpct
return = gt_bapiret2.
call function 'BAPI_TRANSACTION_COMMIT'
importing
return = gt_bapiret2.
endloop.
&----
*& Form upload_file
&----
form upload_file .
ws_filename = p_fn.
Upload input file content
call function 'GUI_UPLOAD'
exporting
filename = ws_filename
filetype = lit_fty
has_field_separator = lit_sep
tables
data_tab = int_src
exceptions
file_open_error = 1
file_read_error = 2
no_batch = 3
gui_refuse_filetransfer = 4
invalid_type = 5
no_authority = 6
unknown_error = 7
bad_data_format = 8
header_not_allowed = 9
separator_not_allowed = 10
header_too_long = 11
unknown_dp_error = 12
access_denied = 13
dp_out_of_memory = 14
disk_full = 15
dp_timeout = 16
others = 17.
endform. " upload_file
&----
*& Form get_filename
&----
form get_filename using value(p_file)
changing p_fn.
call function 'F4_FILENAME'
exporting
field_name = p_file
importing
file_name = p_fn.
endform. " get_filename
please suggest
2007 Oct 22 3:32 PM
Hi ,
Please try using the path, QS41 --> select code group --> go to menu Table view ---> other view ---> select codes from the pop up and then you will be in the codes screen. I hope you might have solved this problem by now, but this is also an option. Please let me know what method you were using to solve this issue.
Regards,
Prabaharan.G
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |