VA03 und speichern?Luigi91 hat geschrieben:Habe bereits die Tabellen XTHEAD und YTHEAD gefunden, sind aber nur gefüllt wenn ich zuvor in den Kopftext oder Postext gesprungen bin.
Nein, der schaut zuerst im Speicher nach! Ggfs. mit dem Parameter LOCAL_CAT experimentieren.Luigi91 hat geschrieben:Funktionsbaustein READ_TEXT funktioniert hier noch nicht, da der ja einen SELECT auf die DB macht. Aber zu diesem Zeitpunkt die Daten noch im MEMORY stehen.
Code: Alles auswählen.
DATA:
BEGIN OF lt_catalog OCCURS 0,
tdobject LIKE thead-tdobject,
tdname LIKE thead-tdname,
tdid LIKE thead-tdid,
tdspras LIKE thead-tdspras,
function(1) TYPE c,
keep(1) TYPE c,
rename(1) TYPE c,
id(6) TYPE n,
copyindex(4) TYPE i,
is_reftext(1) TYPE c,
END OF lt_catalog.
data: wa_catalog like LINE OF lt_catalog.
IMPORT catalog TO lt_catalog FROM MEMORY ID 'SAPLSTXD'.
loop at lt_catalog into wa_catalog where tdobject = 'VBBK' and tdid = '0001'.
ENDLOOP.
wa_catalog-tdobject = 'VBBP'.
wa_catalog-tdname = zlf_vbelnpos.
append wa_catalog to lt_catalog.
EXPORT catalog FROM lt_catalog TO MEMORY ID 'SAPLSTXD'.
Code: Alles auswählen.
DATA:
BEGIN OF lt_catalog OCCURS 0,
tdobject LIKE thead-tdobject,
tdname LIKE thead-tdname,
tdid LIKE thead-tdid,
tdspras LIKE thead-tdspras,
function(1) TYPE c,
keep(1) TYPE c,
rename(1) TYPE c,
id(6) TYPE n,
copyindex(4) TYPE i,
is_reftext(1) TYPE c,
END OF lt_catalog.
data: wa_catalog like LINE OF lt_catalog.
IMPORT catalog TO lt_catalog FROM MEMORY ID 'SAPLSTXD'.
loop at lt_catalog into wa_catalog where tdobject = 'VBBK' and tdid = '0001'.
ENDLOOP.
DATA: itctc like itctc OCCURS 1 WITH HEADER LINE.
itctc-destobject = 'VBBP'.
itctc-destname = zlf_vbelnpos.
itctc-destid = wa_catalog-tdid.
itctc-destlang = wa_catalog-tdspras.
itctc-srcobject = wa_catalog-tdobject.
itctc-srcname = wa_catalog-tdname.
itctc-srcid = wa_catalog-tdid.
itctc-srclang = wa_catalog-tdspras.
APPEND itctc.
BREAK-POINT.
CALL FUNCTION 'COPY_TEXTS'
EXPORTING
SAVEMODE_DIRECT = ' '
INSERT = ' '
LOCAL_CAT = 'X'
IMPORTING
ERROR = zlf_error
TABLES
texts = itctc
.
Code: Alles auswählen.
EXPORT catalog FROM lt_catalog TO MEMORY ID 'SAPLSTXD'.