Update table control dynamically
Dear gurus,
I have created a table control of my internal table "i_main" using Screen Painter's table control wizard. I have made all fields editable via double clicking the field, clicking Program, then Input = Possible.
My i_main table and table control contains the following fields:
hunit TYPE vekp-vpobjkey.
printno TYPE i.
groupno TYPE i.
batch TYPE mseg-charg.
qtyTYPE mseg-menge.
After my program has populated i_main table control, I now want to manually override the contained values in i_main and my table control z_init. When I type in a new value for my quantity column, for example I change 22 to 5. It goes back to 22, and nothing happens.
Any advice on what should I do to update fields of my table control, as well as i_main?
Thank you very much!
in pai event.
loop at iternaltable.
module move_to_table ON CHAIN-REQUEST.
endloop.
module move_TO_TABLE.
MODIFY IT FROM WA_ZTBCTRL INDEX ZTBCTRL-CURRENT_LINE.
ENDMODULE.
Similar Messages
-
Increase number of rows in table control dynamically
Hi,
How can I increase the number of rows in a table control dynamically.If i have placed a table control in the screen painter with 5 rows, how can I increase the length to 10 dynamically in the coding.Kindly advice..
Best Regards,
AshwiniHi aswini,
where did you tell the system to have only 5 rows.
i dont think such an option of specifying the number of rows is possible.
as i reconfirmed the screen painter just now.
please let me know if possible.
try this.
in PBO.
describe table itab lines tc-lines.
if tc-lines is initial.
tc-lines = 5.
else.
tc-lines = 10.
endif.
hope this will serve your purpose.
thanks and regards
Ramchander Rao.Krish
Edited by: ramchander krishnamraju on Nov 19, 2008 11:52 AM -
DYNP_VALUES_UPDATE to update table control cell
How can I update a cell (e.g. in line n) value in a table control using the function DYNP_VALUES_UPDATE? Can someone give me an example?
Thanks in advance.
Adhimas S.Hi,
Check this sample code
REPORT ZVV.
tables tcurt.
DATA DYFIELDS LIKE DYNPREAD OCCURS 1 WITH HEADER LINE.
PARAMETERS: P_WAERS LIKE TCURT-WAERS, "Currency
P_LTEXT LIKE TCURT-LTEXT, "Long Text
P_KTEXT LIKE TCURT-KTEXT. "Short Text
*--- Example of updating value of another field on the screen -
AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_WAERS.
CLEAR: DYFIELDS[], DYFIELDS.
*--- select currency
CALL FUNCTION 'HELP_VALUES_GET'
EXPORTING
fieldname = 'WAERS'
tabname = 'TCURT'
IMPORTING
SELECT_VALUE = P_WAERS.
*--- get long text for the selected currency
SELECT SINGLE LTEXT FROM TCURT
INTO DYFIELDS-FIELDVALUE
WHERE SPRAS = SY-LANGU
AND WAERS = P_WAERS.
IF SY-SUBRC <> 0.
CLEAR DYFIELDS-FIELDVALUE.
ENDIF.
*--- update another field
DYFIELDS-FIELDNAME = 'P_LTEXT'.
APPEND DYFIELDS.
CALL FUNCTION 'DYNP_VALUES_UPDATE'
EXPORTING
DYNAME = SY-CPROG
DYNUMB = SY-DYNNR
tables
dynpfields = DYFIELDS .
*--- Example of reading value of another field -
AT SELECTION-SCREEN ON VALUE-REQUEST FOR P_KTEXT.
*--- read another field
CLEAR: DYFIELDS[], DYFIELDS.
DYFIELDS-FIELDNAME = 'P_WAERS'.
APPEND DYFIELDS.
CALL FUNCTION 'DYNP_VALUES_READ'
EXPORTING
DYNAME = SY-CPROG
DYNUMB = SY-DYNNR
TABLES
DYNPFIELDS = DYFIELDS .
READ TABLE DYFIELDS INDEX 1.
*--- get short text and update current field
SELECT SINGLE KTEXT FROM TCURT
INTO P_KTEXT
WHERE SPRAS EQ SY-LANGU
AND WAERS EQ DYFIELDS-FIELDVALUE.
Thanks & Regards,
Judith. -
How to edit and update table control into database?
I am doing table control. Here are my codes:
*& Report ZHERA_TABLE2
REPORT ZHERA_TABLE2.
***&SPWIZARD: DATA DECLARATION FOR TABLECONTROL 'ZTABLE_CONTROL'
*&SPWIZARD: DEFINITION OF DDIC-TABLE
TABLES: ZHERA.
*&SPWIZARD: TYPE FOR THE DATA OF TABLECONTROL 'ZTABLE_CONTROL'
TYPES: BEGIN OF T_ZTABLE_CONTROL,
NAME LIKE ZHERA-NAME,
AGE LIKE ZHERA-AGE,
END OF T_ZTABLE_CONTROL.
*&SPWIZARD: INTERNAL TABLE FOR TABLECONTROL 'ZTABLE_CONTROL'
DATA: G_ZTABLE_CONTROL_ITAB TYPE T_ZTABLE_CONTROL OCCURS 0,
G_ZTABLE_CONTROL_WA TYPE T_ZTABLE_CONTROL. "work area
DATA: G_ZTABLE_CONTROL_COPIED. "copy flag
*&SPWIZARD: DECLARATION OF TABLECONTROL 'ZTABLE_CONTROL' ITSELF
CONTROLS: ZTABLE_CONTROL TYPE TABLEVIEW USING SCREEN 1000.
START-OF-SELECTION.
CALL SCREEN 1000.
*&SPWIZARD: OUTPUT MODULE FOR TC 'ZTABLE_CONTROL'. DO NOT CHANGE THIS LI
*&SPWIZARD: COPY DDIC-TABLE TO ITAB
MODULE ZTABLE_CONTROL_INIT OUTPUT.
IF G_ZTABLE_CONTROL_COPIED IS INITIAL.
*&SPWIZARD: COPY DDIC-TABLE 'ZHERA'
*&SPWIZARD: INTO INTERNAL TABLE 'g_ZTABLE_CONTROL_itab'
SELECT * FROM ZHERA
INTO CORRESPONDING FIELDS
OF TABLE G_ZTABLE_CONTROL_ITAB.
G_ZTABLE_CONTROL_COPIED = 'X'.
REFRESH CONTROL 'ZTABLE_CONTROL' FROM SCREEN '1000'.
ENDIF.
ENDMODULE.
*&SPWIZARD: OUTPUT MODULE FOR TC 'ZTABLE_CONTROL'. DO NOT CHANGE THIS LI
*&SPWIZARD: MOVE ITAB TO DYNPRO
MODULE ZTABLE_CONTROL_MOVE OUTPUT.
MOVE-CORRESPONDING G_ZTABLE_CONTROL_WA TO ZHERA.
ENDMODULE.
Screen 1000 codes:
PROCESS BEFORE OUTPUT.
*&SPWIZARD: PBO FLOW LOGIC FOR TABLECONTROL 'ZTABLE_CONTROL'
MODULE ZTABLE_CONTROL_INIT.
*&SPWIZARD: MODULE ZTABLE_CONTROL_CHANGE_TC_ATTR.
*&SPWIZARD: MODULE ZTABLE_CONTROL_CHANGE_COL_ATTR.
LOOP AT G_ZTABLE_CONTROL_ITAB
INTO G_ZTABLE_CONTROL_WA
WITH CONTROL ZTABLE_CONTROL
CURSOR ZTABLE_CONTROL-CURRENT_LINE.
*&SPWIZARD: MODULE ZTABLE_CONTROL_CHANGE_FIELD_ATTR
MODULE ZTABLE_CONTROL_MOVE.
ENDLOOP.
MODULE STATUS_1000.
PROCESS AFTER INPUT.
*&SPWIZARD: PAI FLOW LOGIC FOR TABLECONTROL 'ZTABLE_CONTROL'
LOOP AT G_ZTABLE_CONTROL_ITAB.
CHAIN.
FIELD ZHERA-NAME.
FIELD ZHERA-AGE.
ENDCHAIN.
ENDLOOP.
*&SPWIZARD: MODULE ZTABLE_CONTROL_CHANGE_TC_ATTR.
*&SPWIZARD: MODULE ZTABLE_CONTROL_CHANGE_COL_ATTR.
MODULE USER_COMMAND_1000.
Please show me where to put my codes to edit(edit directly on table control fields) and update my table control(using the 'save' button)?Hi,
You have to put the following code in the PBO of screen 1000.This code would make the fields editable to make changes in the table control fields directly.
Here there are 3 transactions.For create and change transactions, the fields will be in editable mode and for display transaction,they will be non editable mode.
DESCRIBE TABLE tb_line LINES lin. " tb_line is the name of the internal table for the table control
tcl_item-lines = lin. '' lin hold the number of lines of the internal table
CASE sy-tcode.
WHEN 'ZCREATE09' OR 'ZCHANGE09'.
***Checking if the table control is empty or not***
IF lin NE 0.
LOOP AT SCREEN.
***To make the screen editable****
screen-input = 1.
ENDLOOP.
ELSE.
LOOP AT SCREEN.
IF screen-name CS 'TB_LINE'.
****To make the screen non-editable if no values are present in the
***table control****
screen-input = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
Once the fields are edited and the save button is pressed,the entered values have to be populated into the Z tables.The code has to written in the PAI of the screen 1000.Here the values from the work area of the internal table are moved into the Z Table. The code will be.
LOOP AT tb_line.
ztm09_ekpo-ebeln = ztm09_ekko-ebeln. "ztm09_ekko and ztm09_ekpo are the names of the Z Tables.
ztm09_ekpo-ebelp = tb_line-ebelp.
ztm09_ekpo-matnr = tb_line-matnr.
ztm09_ekpo-menge = tb_line-menge.
ztm09_ekpo-meins = tb_line-meins.
ztm09_ekpo-netpr = tb_line-netpr.
ztm09_ekpo-waers = tb_line-waers.
*****Update the entries into item table*****
MODIFY ztm09_ekpo.
ENDLOOP.
Reward if helpfull
Thanks,
Kashyap -
Changing number of rows oin a table control dynamically
Hi all
Is there a way to change the no of rows dynamically.
I have a requirement that at run time , depending on a condition, I have to change the no of rows in the table control to 1 row.
Is this possible to do?If else How?
Thanks.You can redefine table control attributes eachtime PBO is called, because those attributes are dynamic. So although you defined tc-lines as 1 in first PBO execution, you can redefine to 2 if some condition is achieved,
One idea could be to create a global var, called tc_lines which is initialized as 1. In your PBO you shoud use: <tc>-lines = tc_lines.
In PAI, when you obtain your condition, you shoud here add or subract one from this global variable.
Regards,
Valter Oliveira. -
Hi All
i have created a table control in that i have two fields
one is o/p filed and another one is i/p filed i have place a f4 for that
and if i press f4 for first column i need values
and if i press f4 for second column i need different values
how to do that
can u please tel some to solve thisHi Suri,
Welcome to SDN
This is test program where in the Table Control Field are taken from ITAB declared in Top Include with fields from table SFLIGHT
PROCESS ON VALUE-REQUEST.
FIELD itab-connid MODULE f4_get.
In Program
MODULE f4_get INPUT.
DATA : fnam TYPE string,
fval TYPE string.
* lin TYPE i.
DATA : BEGIN OF f4_tab OCCURS 0,
carrid TYPE sflight-carrid,
connid TYPE sflight-connid,
END OF f4_tab.
CLEAR lin.
GET CURSOR FIELD fnam VALUE fval LINE lin. " This gives the Current Line in Table Control
DATA : dynpread TYPE TABLE OF dynpread WITH HEADER LINE.
REFRESH dynpread.
CLEAR dynpread.
dynpread-fieldname = 'ITAB-CARRID'.
dynpread-stepl = lin. " You need to pass this line Value here
APPEND dynpread.
CLEAR dynpread.
CALL FUNCTION 'DYNP_VALUES_READ'
EXPORTING
dyname = sy-repid
dynumb = sy-dynnr
TABLES
dynpfields = dynpread
EXCEPTIONS
invalid_abapworkarea = 1
invalid_dynprofield = 2
invalid_dynproname = 3
invalid_dynpronummer = 4
invalid_request = 5
no_fielddescription = 6
invalid_parameter = 7
undefind_error = 8
double_conversion = 9
stepl_not_found = 10
OTHERS = 11
IF sy-subrc IS INITIAL.
READ TABLE dynpread WITH KEY fieldname = 'ITAB-CARRID'.
IF sy-subrc IS INITIAL.
SELECT carrid connid FROM sflight
INTO TABLE f4_tab
WHERE carrid = dynpread-fieldvalue.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'CONNID'
dynpprog = sy-repid
dynpnr = sy-dynnr
dynprofield = 'ITAB-CONNID'
value_org = 'S'
TABLES
value_tab = f4_tab
ENDIF.
ENDIF.
ENDMODULE. " f4_get INPUT
Cheerz
Ram
Edited by: Ramchander Krishnamraju on Nov 17, 2009 10:31 AM -
Using function module DYNP_VALUES_UPDATE to update table control
Hello all
i am using FM "DYNP_VALUES_UPDATE" to update values from search help to dynpro. there are more than 1000 records to be updated, but in table control only visible area values only getting updated. Can any one please help regarding this?
Thanks
NeelimaLook at FM DYNP_GET_STEPL which provides povstepl index to be able to update field values in correct row of table control with DYNP_VALUES_UPDATE (and to read correct value with DYNP_VALUES_READ too)
NB: If you need to update multiple rows, I'm not sure that can be done in POV, you may be required to modify the internal table and trigger PAI/PBO cycle with a suppress dialog, or method/FM to trigger ok_code.
Regards,
Raymond -
Hai
I am saving the datas from table control into ztable. Its saving fine.
If i give the entries exists in ztable it is not inserting. Only new entries is inserting in z table. everything is fine but
my requirement is,
In my table control if it is an existing entry it should come in edit mode and new entries should be inserted and it should remove from table control.
Please help me.If you don't post code, we can't help you. Nethertheless. You must use MODIFY (dbtab) abap statement if you want to insert if it doesn't exist, or update if it exists. Please read the abap reference documentation.
-
Updating Table Columns Dynamically
Hi Everybody,
I have created the following procedure to update table columns, which are having 'N/A' to Null.
PROCEDURE PRC_UPDATE_NA_TO_NULL (p_owner all_tables.owner%TYPE, p_table_name all_tables.table_name%TYPE DEFAULT NULL)
IS
TYPE tc_ref_cursor IS REF CURSOR;
v_tc_ref_cursor tc_ref_cursor;
TYPE nt_column_name IS TABLE OF all_tab_cols.column_name%TYPE;
v_nt_column_name nt_column_name;
v_table_name all_tables.table_name%TYPE;
v_set_str VARCHAR2(4000);
v_where_str VARCHAR2(4000);
v_sql_stmt VARCHAR2(4000);
BEGIN
IF p_table_name IS NOT NULL THEN
OPEN v_tc_ref_cursor FOR
SELECT a.table_name
FROM all_tables a
WHERE a.owner = UPPER(p_owner)
AND a.table_name = UPPER(p_table_name)
ORDER BY a.table_name;
ELSE
OPEN v_tc_ref_cursor FOR
SELECT a.table_name
FROM all_tables a
WHERE a.owner = UPPER(p_owner)
ORDER BY a.table_name;
END IF;
LOOP
DBMS_OUTPUT.PUT_LINE('Processing Owner : '||UPPER(p_owner)||'....');
FETCH v_tc_ref_cursor INTO v_table_name;
EXIT WHEN v_tc_ref_cursor%NOTFOUND;
SELECT b.column_name
BULK COLLECT INTO v_nt_column_name
FROM all_tab_cols b
WHERE b.owner = UPPER(p_owner)
AND b.table_name = UPPER(v_table_name)
AND b.nullable = 'Y'
ORDER BY b.column_id;
IF v_nt_column_name.LAST > 0 THEN
DBMS_OUTPUT.PUT_LINE('Updating '||v_table_name||'....');
FOR i IN v_nt_column_name.FIRST .. v_nt_column_name.LAST
LOOP
v_set_str := v_set_str||v_nt_column_name(i)||' := NULL, ';
v_where_str := v_where_str||v_nt_column_name(i)||' = '||'''N/A'''||' OR ';
END LOOP;
v_set_str := RTRIM(TRIM(v_set_str),',');
v_where_str := RTRIM(TRIM(v_where_str),'OR');
v_sql_stmt := 'UPDATE '||v_table_name||' SET '||v_set_str||' WHERE '||v_where_str;
EXECUTE IMMEDIATE v_sql_stmt;
-- EXECUTE IMMEDIATE 'UPDATE '||v_table_name||' SET '||v_set_str||' WHERE '||v_where_str;
-- EXECUTE IMMEDIATE 'UPDATE :1 SET :2 WHERE :3' USING v_table_name, v_set_str, v_where_str;
COMMIT;
v_set_str := NULL;
v_where_str := NULL;
DBMS_OUTPUT.PUT_LINE('Finished Updating '||v_table_name||'....');
END IF;
END LOOP;
DBMS_OUTPUT.PUT_LINE('Process Over....');
EXCEPTION
WHEN OTHERS THEN
ROLLBACK;
DBMS_OUTPUT.PUT_LINE(SQLCODE||':'||SQLERRM);
END;
The problem I am facing is that the Execute Immediate statement is not working. I have used the Execute Immediate statement in 3 different ways given in the above procedure, but none of them works and the error comes to the Exception section.
Kindly let me have your solutions.
Thanks in advance,
MAKThis approach can be dangerous. You are currently trying to update all columns in the tables to null if any of the columns are 'N/A'. Your query does not exclude external tables which may not be updatable. Your other query does not exclude data types that can not include 'N/A' such as number. You might want to move your commit outside the loop as you may end up committing partial updates.
You might try to capture the SQL that you are generating;
create table t(col2 varchar2(4000));Then in your package;
insert into t values(v_sql_stmt);
-- EXECUTE IMMEDIATE v_sql_stmt; -
Making a field visible for a particular row in table control.
Hi Experts,
I have a scenario where in there are 7 columns in table control wherein last column I have made invisible. Now I got to make that column visible only for the selected row and this column for the rest of the rows should be invisible.
How can I achieve this. Tried a lot playing with table control current line and cols structure but no fruit.
Please help. <removed by moderator>
Thanks,
Edited by: Thomas Zloch on Oct 19, 2010 2:38 PMHi All,
Sorry for late response. I was out of station for a while.
I tried a lot after going through the link provided by Robert and also tried what Anmol has suggested but its not working,
The column becomes invisible but it is not becoming visible again for the selected row.
The code I have written is as follows.
process before output.
module status_9000.
module tc_details_change_tc_attr.
loop at it_test
into wa_test
with control tc_details
cursor tc_details-current_line.
module tc_details_get_lines.
module customize. " Module to update table control dynamically
endloop.
module CUSTOMIZE output.
LOOP AT TC_DETAILS-cols INTO cols.
if cols-screen-name = 'WA_TEST-REMARKS'. " and wa_test-sel = 'X' ).
IF WA_TEST-SEL = 'X'.
COLS-SCREEN-ACTIVE = '1'.
COLS-INVISIBLE = '0'.
MODIFY TC_DETAILS-COLS FROM COLS INDEX SY-TABIX.
ELSE.
COLS-SCREEN-ACTIVE = '0'.
COLS-INVISIBLE = '1'.
MODIFY TC_DETAILS-COLS FROM COLS INDEX SY-TABIX.
ENDIF..
ENDIF.
ENDLOOP.
endmodule.
Please help. -
Hi Experts,
My Requirement is create a table control with 5 coloumns. The rows have to be displayed dynamically...
I created a screen , and placed a table control.
For eg :
if my internal table having 2 entries , then the table control should only have two rows....(no disable/greyout)
if internal table having say 40 entries , then the table control should have 40 rows...
Thanks,
Lakshmiraj.AHi,
Refer
table control dynamic rows
Dynamic rows increment according to user input in Table Control Module Pool
Hope this helps
Sumana -
Dynamic Table control header text
Hi everyone,
I need to change the column header texts of a table control dynamically.
There are 32 columns in my table control. I got the information that I have to use I/O fields for every columns as the column header texts to change it dynamically.
But it didn't work as the I/O box goes into the body of the table control instead of being placed in the header area. So I checked w/title and tried to drag and drop the I/O boxes on the header text place of table control. But it allowed only one I/O box to be there in the header area..
Please suggest me any idea to place the 32 I/O boxes in the header area as the corresponding column headers in the table control..
Thanks in advance,
Sheeba.Resolved the issue..
-
Hi friends,
I am having a problem when sorting the table control dynamically based on the fields selectd.
sorting is not working, when you select multiple fields ( one numeric field and one character field ) I have written code for handling multiple field sort,gettting field names correctly, everything looks fine but internal table is not getting sorted.
Is it related unicode issue..?
Any help will be appreciated.
Sample code:
loop at tc_control into lc_cols.
case lc_cols-selected.
wehn 'X'.
split lc_cols-screen-name at '-' into gv_tabname gv_fieldname.
move gv_fieldname gs_struc+lv_off(20)
add 20 to lv_off.
endcase.
endloop.
if ok_code = 'ASCE'.
sort itab by (gs_struc-field1) (gs_struc-field2) ..... ascending
endif.
Thanks in advance
Thiru.pHi
Try using an internal table for the field names..
Example
DATA: BEGIN OF ITAB OCCURS 0,
MATNR TYPE MATNR,
WERKS TYPE WERKS_D,
END OF ITAB.
DATA: ITAB_FIELD(30) OCCURS 0 WITH HEADER LINE.
DATA
ITAB-MATNR = 'ABC'.
ITAB-WERKS = 'ABCD'.
APPEND ITAB.
ITAB-MATNR = 'ABC'.
ITAB-WERKS = 'ABC'.
APPEND ITAB.
SORT INTERNAL TABLE
ITAB_FIELD = 'MATNR'.
<b>APPEND ITAB_FIELD.</b>
ITAB_FIELD = 'WERKS'.
<b>APPEND ITAB_FIELD.</b>
<b>SORT ITAB BY (ITAB_FIELD).</b>
LOOP AT ITAB.
WRITE: / ITAB-MATNR,ITAB-WERKS.
ENDLOOP.
Thanks
Naren -
Dynamically resizing table control
Hi all,
I have designed a table control in the screen. in that, I have fixed the number of columns (7) using Fixed coulmns option in the screen painter. But, when the user selects an option (radio button) in the screen, I will hide two columns of the table control. So, now I want to resize the table control i.e. reduce the horizontal width of the table control.
How can I achieve this?
Please help me....
Thanks,
RajanHi,
Suppose your screen is 9000
Now in PBO define a module set_attr_table and handle
handle it via your button -
PROCESS BEFORE OUTPUT.
MODULE status_9000.
MODULE set_attr_table.
LOOP AT t_lips3 INTO w_lips3_ds WITH CONTROL
t_inbd CURSOR t_inbd-top_line.
ENDLOOP.
Where if you have already defined
CONTROLS: t_inbd TYPE TABLEVIEW USING SCREEN '9000'.
t_lips3 is the table you are using to display records from.
In the module set_attr_table try to change the the table control dynamically -
DATA: w_ls_cer_inbd_ds LIKE LINE OF t_inbd-cols.
Try to modify the column attributes dynamically by modifying the screen table contents
LOOP AT t_inbd-cols INTO w_ls_cer_inbd_ds.
IF sy-tabix = 5 or sy-tabix = 6.
w_ls_cer_inbd_ds-invisible = 1.
MODIFY t_inbd-cols FROM w_ls_cer_inbd_ds TRANSPORTING invisible.
ENDIF.
ENDLOOP.
Say column 5 and 6 you want to change.
Thanks -
Multiple selection in F4 help in table control
Hi,
I am providing F4 help for a particular field in the table control. User must be able to select multiple values from this F4 help this is done using the function module F4IF_INT_TABLE_VALUE_REQUEST. Now the selected fields have to be transferred to screen, this is done using FM DYNP_VALUES_UPDATE.
My problem is i have 6 rows displayed in my table control. So only first 6 values from the user selected values are getting updated in my screen fields others are not getting updated. Say if the user selects 10 values out of them only 6 is populating in the screen. How do i get the others also? Please help.
Thanks,
KarthikHi,
Check the Following threads
can we select multiple entries from a F4 result?
Table Control dynamic F4
After you select Multiple rows from F4 Help these are stored in RETURN table.
Now in main program modify the Internal Table.
In PAI
loop at itab.
" You can not handle this in this Loop
endloop.
module modify_from_f4
process on value-request
field fname module get_f4 " Here you get the F4 Help and the values are in RETURN tab
in Program
module modify_from_f4.
" in this module you can use the RETURN TAB like
loop at itab
read table RETURN with key fnam = itab-fnam " and get the corresponding value and modify itab from RETURN tab
if you can not find common fields and just want to pass the values then
read table RETURN INDEX SY-TABIX. " IF the Itab is empty then follow below loop
endloop.
loop at return.
move return-fieldvalue to itab-fnam
append itab.
endloop.
endmodule.
Cheerz
Ram
Maybe you are looking for
-
I am creating a report from a series of inputs using a customizable date range. I need to select a start and end date (i was going to use two calendars for that) and place the data from the range into a pivot table. Any help on how to do this would b
-
A few questions from a REAL beginner
OK, so I am very very very new to HTML, CSS and Dreamweaver and I have a few questions. But before I start let me just state that I have been messing around with HTML, CSS and Dreamweaver for like one week so take it easy if these questions are obvio
-
How to use BAPI_ACC_DOCUMENT_POST
Hello ALL. I need to update the field AUFNR in database table BSEG, I'm using the BAPI BAPI_ACC_DOCUMENT_POST, the function module execute with out errors, but do not change the field AUFNR. Could any one help me? Thanks in advance
-
Currently I am writing a German help text including 'special characters' such as umlauts (ä, ö, ü, ...). I would also would like to include German quotation marks represented by the html names "bdquo;" and "rdquo;" But this does not work. Any idea? (
-
Tecra 750: Question about Infrared and TV remote control
Hi there, I am wondering if anyone can help. I have an old Tecra 750 which I am using as an audio system to play my MP3 collection. It has an Infrared detector on it and I was wondering if it is possible to use this to receive IR from a TV remote con