Re: control table VS bdc
Hi,
I wirtten bdc code to enter the TASKS data into iw22 tcode which contains table control for this. I written the code and it is successfully executing if iam entering new items into tcode if there is no data. But if any data exits in the table control, when i try to change the values it is giving problem. problem si that table control contains 17 lines. So iam using pagedown every 17 lines. But it is skipping
line items after 17 and it is showing last line item in the table control. So what is the solution to see the 18 line item. I appreciate ur help.
Just check it out below code and run this code in ur system and enter the notification number.
rgds
p.kp
data: bdctab like bdcdata occurs 0 with header line,
bdcmsg like bdcmsgcoll occurs 0 with header line,
it_viqmsm like viqmsm occurs 0 with header line.
parameter: qmnum(12) type n.
DATA : I(2) TYPE n,
y(2) type n,
v_fnam(30) TYPE c,
vlines(2) type c value 17,
z type i,
z1 type i,
n type i.
field-symbols: <fs>.
start-of-selection.
do 1 times.
perform main.
call transaction 'IW22' using bdctab
mode 'A'
update 'S'
messages into bdcmsg.
if sy-subrc <> 0.
loop at bdcmsg.
CALL function 'MESSAGE_TEXT_BUILD'
exporting
msgid = bdcmsg-msgid
msgnr = bdcmsg-msgnr
IMPORTING
MESSAGE_TEXT_OUTPUT = bdcmsg-fldname.
modify bdcmsg transporting fldname.
endloop.
endif.
enddo.
loop at bdcmsg.
write: / bdcmsg-msgv1,bdcmsg-msgv2,bdcmsg-fldname.
endloop.
form main.
perform bdc_dynpro using 'SAPLIQS0' '0100'.
perform bdc_field using 'BDC_CURSOR'
'RIWO00-QMNUM'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'RIWO00-QMNUM'
qmnum.
perform bdc_dynpro using 'SAPLIQS0' '7200'.
perform bdc_field using 'BDC_OKCODE'
'=10\TAB11'.
select * from viqmsm into table it_viqmsm
where qmnum = qmnum.
describe table it_viqmsm lines y.
if y = 0.
assign n value for no of items
this is for change if already exits
suppose
n = 19.
else.
n = y.
endif.
DO n TIMES.
I = I + 1.
********after fill up one page************
IF I > vlines.
if y <> 0.
z1 = z1 + 1.
z = n - vlines * z1.
if z > 0.
I = 1.
else.
I = 2.
endif.
else.
i = 2.
endif.
perform bdc_dynpro using 'SAPLIQS0' '7204'.
perform bdc_field using 'BDC_CURSOR'
V_FNAM.
perform bdc_field using 'BDC_OKCODE'
'=PEND'.
ENDIF.
*******to enter the data*******************
clear: v_fnam.
CONCATENATE 'VIQMSM-MNGRP' '(' I ')' INTO V_FNAM.
perform bdc_dynpro using 'SAPLIQS0' '7204'.
perform bdc_field using 'BDC_CURSOR'
V_FNAM.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using V_FNAM
'm095'.
clear: v_fnam.
CONCATENATE 'VIQMSM-MNCOD' '(' I ')' INTO V_FNAM.
perform bdc_field using 'BDC_CURSOR'
V_FNAM.
perform bdc_field using V_FNAM
'M95B'.
*******end of enter data*********************
ENDDO.
perform bdc_dynpro using 'SAPLIQS0' '7204'.
perform bdc_field using 'BDC_CURSOR'
V_FNAM.
perform bdc_field using 'BDC_OKCODE'
'=BUCH'.
endform.
*& Form bdc_dynpro
text
-->P_0039 text
-->P_0040 text
form bdc_dynpro using value(p_0039)
value(p_0040).
bdctab-program = p_0039.
bdctab-dynbegin = 'X'.
bdctab-dynpro = p_0040.
append bdctab.
clear bdctab.
endform. " bdc_dynpro
*& Form bdc_field
text
-->P_0044 text
-->P_0045 text
form bdc_field using value(p_0044)
value(p_0045).
bdctab-fnam = p_0044.
bdctab-fval = p_0045.
append bdctab.
clear bdctab.
endform. " bdc_field
before doing the page down u have to check the Input values.
Regards
Prabhu
Similar Messages
-
Dear abaper
Can u Pl let me to how to handle table control in ME51 BDC.
if u have program send it to [email protected]
rgds,
SimhaRegarding Table comtrols in BDC...
Normally all the screns with table controls will have buttons to add(Insert) a Row, Delete a Row etc..
After adding data to 1st Row (it will have index 1)... press that insert button so a new Row is inserted again at 1st row..so this will have index 1.
So in this way you can hard code the index to one.
The advantage is that if there are many rows then you will not have to keep a track of how many rows are inserted and when to press the page down button.
I am giving a small example.... Just copy paste this example and run it in all mode...
Run it in all mode so that you can see what I am trying to do...
Note : this is an relatively easy method.. not the only method to do...
report ZTEST_BDC
no standard page heading line-size 255.
include bdcrecx1.
start-of-selection.
perform open_group.
perform bdc_dynpro using 'SAPMSRD0' '0102'.
perform bdc_field using 'BDC_CURSOR'
'RSRD1-DDTYPE'.
perform bdc_field using 'BDC_OKCODE'
'=CHANGE_RADIO'.
perform bdc_field using 'RSRD1-TBMA'
perform bdc_field using 'RSRD1-TBMA_VAL'
'EKPO'.
perform bdc_field using 'RSRD1-DDTYPE'
'X'.
perform bdc_dynpro using 'SAPMSRD0' '0102'.
perform bdc_field using 'BDC_CURSOR'
'RSRD1-DDTYPE_VAL'.
perform bdc_field using 'BDC_OKCODE'
'=ADD'.
perform bdc_field using 'RSRD1-TBMA_VAL'
'EKPO'.
perform bdc_field using 'RSRD1-DDTYPE'
'X'.
perform bdc_field using 'RSRD1-DDTYPE_VAL'
'ztest_Str'.
perform bdc_dynpro using 'SAPLSED1' '0100'.
perform bdc_field using 'BDC_CURSOR'
'D_100-STRU'.
perform bdc_field using 'BDC_OKCODE'
'=GOON'.
perform bdc_field using 'D_100-DTEL'
perform bdc_field using 'D_100-STRU'
'X'.
perform bdc_dynpro using 'SAPLSD41' '2100'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'DD02D-DDTEXT'
'test'.
perform bdc_field using 'BDC_CURSOR'
'DD03P_D-FIELDNAME(01)'.
perform bdc_field using 'DD03P_D-FIELDNAME(01)'
'bukrs'.
perform bdc_field using 'DD03P_D-ROLLNAME(01)'
'bukrs'.
perform bdc_dynpro using 'SAPLSD41' '2100'.
perform bdc_field using 'BDC_OKCODE'
'=WB_LINE_INSERT'.
perform bdc_field using 'DD02D-DDTEXT'
'test'.
perform bdc_field using 'BDC_CURSOR'
'DD03P_D-FIELDNAME(01)'.
perform bdc_dynpro using 'SAPLSD41' '2100'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'DD02D-DDTEXT'
'test'.
perform bdc_field using 'BDC_CURSOR'
'DD03P_D-ROLLNAME(01)'.
perform bdc_field using 'DD03P_D-FIELDNAME(01)'
'kostl'.
perform bdc_field using 'DD03P_D-ROLLNAME(01)'
'kostl'.
perform bdc_dynpro using 'SAPLSD41' '2100'.
perform bdc_field using 'BDC_OKCODE'
'=WB_LINE_INSERT'.
perform bdc_field using 'DD02D-DDTEXT'
'test'.
perform bdc_field using 'BDC_CURSOR'
'DD03P_D-FIELDNAME(01)'.
perform bdc_dynpro using 'SAPLSD41' '2100'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'DD02D-DDTEXT'
'test'.
perform bdc_field using 'BDC_CURSOR'
'DD03P_D-ROLLNAME(01)'.
perform bdc_field using 'DD03P_D-FIELDNAME(01)'
'wrbtr'.
perform bdc_field using 'DD03P_D-ROLLNAME(01)'
'wrbtr'.
perform bdc_dynpro using 'SAPLSD41' '2100'.
perform bdc_field using 'BDC_OKCODE'
'=WB_SAVE'.
perform bdc_field using 'DD02D-DDTEXT'
'test'.
perform bdc_field using 'BDC_CURSOR'
'DD03P_D-ROLLNAME(01)'.
perform bdc_dynpro using 'SAPLSTRD' '0100'.
perform bdc_field using 'BDC_CURSOR'
'KO007-L_DEVCLASS'.
perform bdc_field using 'BDC_OKCODE'
'=TEMP'.
perform bdc_field using 'KO007-L_AUTHOR'
'VARUN'.
perform bdc_dynpro using 'SAPLSD41' '2100'.
perform bdc_field using 'BDC_OKCODE'
'/EWB_CANCEL'.
perform bdc_dynpro using 'SAPMSRD0' '0102'.
perform bdc_field using 'BDC_OKCODE'
'/EABR'.
perform bdc_field using 'BDC_CURSOR'
'RSRD1-DDTYPE_VAL'.
perform bdc_transaction using 'SE11'.
perform close_group.
I hope this helps.....
Please mark points if it helps.. -
Table control resolution in BDC
Hi
All
I have one doubt regarding table control resolution in BDC .I know how to handle table control like if i have 5 rows in my TABLE CONTROL.I write the logic according to this rows and if more than 5 rows are there in my flat file i extend the atble control.But this logic will fail in some other system if more than 5 rows are there in that syatem. But I have read from some where that we can use ctu_params structure and if we pass default size as 'x' then it automatically take cares in every sysem.But my doubt is while writing the code initially how can we write ie i mean how many rows i have to mention initially in my logic .
Please tell me the answer to this question if you have already face this type of problem.
Thanks and regards
VenkateswarHi,
The numeber of lines of table control for BDC depend on screen resolution, but It can't be managed by program.
So the better solution is to create a bdc doesn't depend on resolution.
It can do that using always the first two lines of table control.
When you start the simulation, first record has to be placed in first line of tc and the second in second one.
Before placing the third record, it needs to place the second record to the top and so the third record can be placed in the second line.
Before placing the next record, it needs to place the third record to the top and so the fourth record can be placed in the second line and so.
In this way your BDC'll use alwways the first two lines of tc and your program won't depend on resolution.
The problem is the transaction you need to simulate by BDC has to have a scroll functionality to allow to place the last record was elaborated to the top of tc, so the second line of tc can always be used to place the new record.
If there isn't this functionality, it's better to use a BAPI instead of BDC.
check these...
http://www.abaplearning.com/index.php?option=com_fireboard&Itemid=2&func=view&id=11&catid=8
BDC - standard screen resolution required?
https://forums.sdn.sap.com/click.jspa?searchID=739193&messageID=823953
Regards,
Omkaram. -
How to make a control table with the same number of rows of its itab
I'm creating a control table, but it always have the maximum number of lines possible.
How can I make it so that it has only the same number of rows of it's internal table?solved partialy with this:
MODULE locka_lin OUTPUT.
DATA: lin TYPE i.
DESCRIBE TABLE t_obj LINES lin.
table_con-lines = lin.
ENDMODULE. " OUTPUT
but it still doent work when lin = 0
any simple way to solve it on that case?
Edited by: RagnaRock on May 5, 2010 6:00 PM -
How to remove the default members of a dimension from the control table?
Hi all,
I am new to hyperion FDM 11.1.1.2.0.0 .
When I navigate to Metadata>Control Tables and try to delete the default memmbers
for the dimension like category and period i got the following error.
Error: Period( 8/31/2009 ) is an active Global or Local Period and cannot be deleted.
Then again i unchecked active checkbox for that dimension from Hyperion Essbase Integration Setup of Workbench Client.
After doing that i got the following error
Error: Unable to retrieve target System Data.
Can anyone tell me how to remove the default members of a dimension from the control table?
ThanksCreate a new record for the table.
Go change the POV to the new record.
Return to the control table and delete the default record. -
FI- Line Item Extraction- BWOM_SETTINGS- Control Table Entries
Gurus,
I am working on FI- Line item extraction in the sand box. I have all my DS's in Nodes not connected. I transfereed the application component hierarchy in SBIW. Now I went to check on the basic settings before activating the DS's for FI line item- in the control table, BWOM_SETTINGS, I could not find any parameters- lowlimit, safety, there are only 2 parameters-OBJSELSICO-'X', and OBLIGODELT- ' '.
We can enter the param values manually and transfer global settings to BI. Could we do the same for fields too. Could we enter them manually?
Why does my control table doesn't have the fields for std line item extraction- lowlim, safety, timbor, overla. My plug- ins are good. I have all the plug ins. I can see them in dev box but not sand box. Why?Hi Ram,
I think Time stamp will set in this table when we run first delta or init in BI system.
So activate the data source and replicate the same BI system. develop data model for this data source and run the init for this data source.
then you will be able to find time stamp for this data source.
FI-Line item data-Delta.
0FI_GL_4 delta functionality?????
Regards,
Venkatesh -
Show zeroes in a control table (Module Pool)
Hi all.
I need showing zeroes in a control table.
I declared fields type char in the control table (and in the internal table) and it shows zeroes, but I need declare it type QUAN (control table and internal table).
With all types (except CHAR) I couldn't show de zeroes there.
If anybody can help me, I Will be grateful!Hi,
In your PBO, inside LOOP ENDLOOP, have a module for screen modifications and for the last row that has totals, you set screen-invisible = 1 inside LOOP AT SCREEN. ENDLOOP.
For example,
If your screen has following PBO Logic,
MODULE ...
MODULE ...
LOOP ...
****New module here for screen modification if does not ****exist already.
MODULE modify_screen.
ENDLOOP.
and then in MODULE modify_screen.
MODULE modify_screen.
****Basically check MATNR EQ 'TOTAL' or some thing like ****that
IF <your condition for totals line>.
LOOP AT SCREEN.
****Note instead of screen-name, you can assign a screen ****group to all columns w/o totals and then use
****SCREEN-GROUP1 EQ <your grp> logic
IF screen-name EQ <your column name w/o totals>.
screen-invisible = 1.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
ENDMODULE.
On another note, since you are already disabling this fields in the last row, you have all the screen modification logic already I guess, so just add SCREEN-INVISIBLE = 1 for all fields w/o totals..
Hope this helps..
Sri
Message was edited by: Srikanth Pinnamaneni -
Cannot see data in SAP.Web.UI.Controls.Table
Hi,I have created a portal project and dragged a sap table into the design area. then i call a webservice and bind the resulting dataset to the table. the dataset seems to bind, since i can see there are the right number of pages in the table, but i cannot see any of the data. all the rows are blank. am i treating the ascx file correctly? i deploy and browse to test it.
this is the code in the aspx:
<%@ Register TagPrefix="sap" Namespace="SAP.Web.UI.Controls" Assembly="SAP.Web, Version=1.2.0.0, Culture=neutral, PublicKeyToken=50436dca5c7f7d23" %>
<%@ Control language="vb" Codebehind="PortalComponent1.ascx.vb" AutoEventWireup="false" Inherits="pdkdemo2.PortalComponent1" targetSchema="http://schemas.microsoft.com/intellisense/ie5" %>
<!%@ PortalComponent name="PortalComponent1" %>
<LINK href="C:\Program Files\SAP\SAP Portal Development Kit for .NET 1.0\Controls\ur\ur_design.css"
type="text/css" rel="stylesheet">
<body class="prtlBody">
<sap:Table id="Table1" runat="server">
<sap:Caption Text="Table" ID="Caption2"></sap:Caption>
<sap:TableRow ID="Table1_ItemTemplate">
<sap:TableCell ID="TableCell4" Title="Column1">
<sap:TextView ID="TextView4"></sap:TextView>
</sap:TableCell>
<sap:TableCell ID="TableCell5" Title="Column2">
<sap:TextView ID="TextView5"></sap:TextView>
</sap:TableCell>
<sap:TableCell ID="TableCell6" Title="Column3">
<sap:TextView ID="TextView6"></sap:TextView>
</sap:TableCell>
</sap:TableRow>
</sap:Table>
</body>
and this is the code behind:
Imports System
Imports System.Collections
Imports System.ComponentModel
Imports System.Data
Imports System.Drawing
Imports System.Web
Imports System.Web.UI
Imports SAP.Portal.Web.UI
Imports SAP.UI
Imports SAP.Web.UI.Controls
Public class PortalComponent1
Inherits SAP.Portal.Web.UI.PortalComponent
Protected WithEvents Table1 As SAP.Web.UI.Controls.Table
Protected WithEvents Caption1 As SAP.Web.UI.Controls.Caption
Protected WithEvents Table1_ItemTemplate As SAP.Web.UI.Controls.TableRow
Protected WithEvents TableCell1 As SAP.Web.UI.Controls.TableCell
Protected WithEvents TextView1 As SAP.Web.UI.Controls.TextView
Protected WithEvents TableCell2 As SAP.Web.UI.Controls.TableCell
Protected WithEvents TextView2 As SAP.Web.UI.Controls.TextView
Protected WithEvents TableCell3 As SAP.Web.UI.Controls.TableCell
Protected WithEvents Caption2 As SAP.Web.UI.Controls.Caption
Protected WithEvents TableCell4 As SAP.Web.UI.Controls.TableCell
Protected WithEvents TextView4 As SAP.Web.UI.Controls.TextView
Protected WithEvents TableCell5 As SAP.Web.UI.Controls.TableCell
Protected WithEvents TextView5 As SAP.Web.UI.Controls.TextView
Protected WithEvents TableCell6 As SAP.Web.UI.Controls.TableCell
Protected WithEvents TextView6 As SAP.Web.UI.Controls.TextView
Protected WithEvents TextView3 As SAP.Web.UI.Controls.TextView
Private Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Load
Dim proxy As New secblrnd.Service1
Dim ds As DataSet
ds = proxy.GetData("U020_EQUIP", "ALL", "NO", 0, "MOODLET1", "MOODLET1")
Table1.DataSource = ds
Table1.DataBind()
End Sub
#Region "Web Form Designer generated code"
Protected Overrides Sub OnInit(ByVal e As EventArgs)
' CODEGEN: This call is required by the ASP.NET Web Form Designer.
InitializeComponent()
MyBase.OnInit(e)
End Sub
' Required method for Designer support - do not modify
' the contents of this method with the code editor.
Private Sub InitializeComponent()
End Sub
#End Region
End class
any assistance would be highly appreciated.Hi,
The problem is that the SAP table doesn't support this kind of "dynamic binding" at the moment. The SAP table can contain any one of several controls in each cell, and these controls have several possible properties to bind to. So currently you have to "tell" the table what you want to bind to.
You have several options:
1. The easiest option, if you can create a typed dataset in design-time, according to what your webservice returns, then do that... and then put an instance of it on your portal component, and bind your table to that typed dataset (using the designer property grid). This should create a default ItemTemplate with all textViews in the cells, and the texts will be bound to the columns.
2. Write code in ItemCreated Event handler of the table. This event will be raised for each row in the DS. There you can tell the cells to get the data from the content. Remember that you'd have to create the cells according to the number of columns and set the content of each cell to be what control you want (like TextView) and then fill the properties of that control.
3. If you know the Data structure, but don't want to or can't create a typed DataSet - First define the columns using the designer (right click the table, select "edit columns"). Then in the event handler (from "2") just set the property "text" of each TextView which is in the content of each cell (use the Cell's property "TableCellContent" to get to the TextView control)
4. Don't use databinding and create the table contents completely manually (See here -
How to modify cells in a table?)
One last thing, here's a link to some more explanations about DataBinding in SAP controls:
https://media.sdn.sap.com/html/submitted_docs/PDK_for_dotNET_10/Programming%20with%20PDK%20for%20.NET/SAP%20NetWeaver%20.NET%20Controls/Data%20Binding/Complex%20Data%20Binding.htm
If you choose a solution and need more help, just ask.
Regards,
Ofer -
Issue with Period Control Table after copying Essbase adapter
Hi Experts,
I'm working on version 11.1.1.3 and have copied the adapters (Essbase, Pull + EPRi) in the work bench so I can add an additional target for the FDM application. However, I have an issue with the import process; it returns an error with the Time & Periods (I guess it's something to do with the Periods category).
I have reimported the Periods Control Table and updated the new application's Target Period & Year (whilst changing the system code in the Application settings to the newl adapter) and still receive the same error message.
Any direction or thoughts would be welcome.
Thanks
MarkThe time periods do not copy. You need to maintain them through the UI or upload them from excel. There is a KM article on this if you need additional detail.
-
Fetch records from ETL Load control tables in BODS
Hi,
Please anyone tell me, how to fetch the records from the ETL Load control tables in BODS.
(E.g) ETL_BATCH, ETL_JOB, ETL_DATAFLOW, ETL_RECON, ETL_ERROR.
These are some ETL load tables..
Thanks,
Ragrds,
Ranjith.Hi Ranjith,
You can ask your administrator for BODS repository login details.
Once you get login details you will get all the tables.
Please check following links :
Data Services Metadata Query Part 1
http://www.dwbiconcepts.com/etl/23-etl-bods/171-data-services-metadata-query-part-2.html
http://www.dwbiconcepts.com/etl/23-etl-bods/171-data-services-metadata-query-part-3.html
I hope this will help.
If you want more info then please let me know.
Thanks,
Swapnil -
What is control tables in abap hr?what is the purpose?
what is control tables in abap hr?what is the purpose?
These are the screen elements used to display tabular data they can be called
as screen tables( like STEP LOOP).To use table control we have to create it on the screen using SCREEN PAINTER(SE51) and declare a control variable of TYPE TABLEVIEW using CONTROLS statement in the ABAP program. We have to use LOOP .. ENDLOOP statement in both PBO and PAI with or without AT int_table parameter. IF AT int_table parameter is not used than we have to place a MODULE call between the LOOP...ENDLOOP statement to fill the screen table rows from the ABAP program in PBO and program our own scrolling functions
using OK_CODE field.
Having a parallel loop(at screen table rows & int table rows) by using parameter
AT int_table makes the ABAP code simple.
A special structure of type CXTAB_CONTROL is used to set/get various
attributes of table control at runtime like CURRENT_LINE ,TOP_LINE.
ABAP declaration
CONTROLS: tab_con TYPE TABLEVIEW USING SCREEN nnnn
Here tab_con is the same name we used in screen for the table control.
This ABAP statement will declare a control variable that will be used to access
the table control , and set it's various attributes like number of fixed columns(tab_con-FIXED_COLS) ,total number of records it will display(tab_con-LINES).It is of type CXTAB_CONTROL and is a deep structure(structure containing structures).
REFRESH CONTROL tab_con FROM SCREEN nnnn
This ABAP statement will initialize the table control on the screen nnnn to its initial values.
PBO processingI
n PBO we have to use the screen LOOP ...ENDLOOP statement , with or without
intenal table.
LOOP WITH CONTROL tab_con.
MODULE fill_tab_con.
ENDLOOP.
Here a module should be called between the loop endloop statement to transfer
data from th ABAP program to the screen table through a structure.This module
should use the CURRENT_LINE attribute of the table control variable to get the
current screen table record index to read the data from the internal table into a work area.
e.g.
READ TABLE int_table INDEX tab_con-CURRENT_LINE
The record read will be placed in the header line of the internal table and will be available to the similarly named screen fields or if these are different it can be written explicitly. e.g.
screen_field_name = int_table-field_name
LOOP AT int_table INTO workarea WITH CONTROL tab_con CURSOR i FROM
n1 TO n2.
ENDLOOP.
Here the module call is not required to fill the screen table.The CURSOR parameter is a integer of type I indicating which absolute internal table line
should be the first to display on the table control .FROM n1 TO n2 can be used
to restrict the starting line and ending line number of the internal table , they are of type SY-TABIX.
In both cases before the LOOP statement a module should be called which
is generally for setting of status ,in which we should fill the LINES attribute
(tab_con-LINES ) of the control with the total number of internal table records,doing this ensures correct and automatic scrolling.
The ABAP statement DESCRIBE TABLE int_table LINES lines can be used
to get the total lines in an int table.
PAI Processing
We have to use LOOP ... ENDLOOP in PAI so that data can transfer fro table control to ABAP program. If we want to write changes to the data we should
call a module between the LOOP ... ENDLOOP. The MODULE call to process user commands (SY-UCOM) should be called after the ENDLOOP statement.
e.g.
PROCESS AFTER INPUT
MODULE mod AT EXIT-COMMAND.
LOOP AT itab_table or LOOP "depending on whether we are using AT int_table
MODULE modify_int_table.
ENDLOOP.
MODULE user_command.
In the MODULE call modify_int_table we can use
MODIFY int_table FROM workarea INDEX tab_con-CURRENT_LINE
or we can use
int_table-field_name = screen_field_name.
Thanks
Please Reward points if helpful.
Edited by: Richa Khosla on Mar 28, 2008 7:38 AM -
In the SD certification material , its said that various masters and control tables are used for processing the sales order .can any one explain me what is control table?
Rgds
RamprasadHi Ram Prasad,
Please find below the information :
1) Screen tables
A table can be created in transaction. These tables, when designed on the screen are called as SCREEN TABLES.
These are of two types.
Table Controls and Step loops
These tables are treated as Loops.
2)Features of Table Controls
Data is displayed in the form of table.
Table control gives user the feeling of an actual table.
You can scroll through the table vertically as well as horizontally.
You can select rows and columns.
You can resize the with of columns.
You can have separator lines between rows and columns.
Automatic resizing of the table when the user resizes the window.
You can update information in the table control and it can be updated in the database table by writing code for it.
3)Steps for creating table control
Declaration of table control in module pool program.
Designing of table controls on the screen.
Passing data to table control in flow logic.
4)Declaration of TC in MPP
syntax:
controls <name of table control> type tableview using screen <escreen no.f>.
5)Designing Table control on screen
Click on Table in Control bar and place it on the screen. You can adjust the length and width of the Table Control.
Name the table control.(same name as given in data declaration).
From dictionary object OR from program fields select the fields and place them in the table control
6)Passing data to table control
Usually transfer of data from program to screen is automatic.
In case of TC, you need to explicitly transfer the data to table control.
ABAP/4 provides Loop statement, which is associated with flow logic to transfer the data.
7)Passing of data contd.
PBO.
Loop at <name of internal table> with control <name of table control> cursor <scroll variable>.
modulecc.
Endloop.
PAI.
Loop at < name of internal table>.Endloop.
8)Scroll variables
Top_line : the row of table where the screen display starts.
Current_line : the row currently being processed inside a loop.
9)Transfer of data from prg to TC.
With eLoop at cf statement, the first row is placed in the header of internal table.
If any module is specified between Loop and End loop, it will be executed. In this module, generally we will be assigning this internal table fields to table control screen fields.
The row in internal table is transferred to the TC as stated in the eLoop atc..f statement.
The system encounters the eEndloopf statement and control is passed back to the next line of internal table.
In the same way all the records of the internal table are passed to the TC.
Find the fallowing some tables avail in SD
SAP SD Tables
VBAK -
(SALES DOC HEADER)
VBAP -
(SALES DOC ITEM)
VBFA -
(SALES DOC FLOW)
VBUK -
(SALES DOC HEAD. STATUS)
VBUP -
(SALES DOC ITEM STATUS)
LIKP -
(DELIVERY HEAD DATA)
LIPS -
(DELIV ITEM DATA)
MSEG -
(MAT DOC SEGMENT)
MKPF -
(MAT.DOC)
VBRK -
(INV HEADER)
VBRP -
(INV ITEM)
BSEG -
(ACC DOC SEGMENT)
BKPF -
(ACC DOC HEADER)
KNA1 --- General Data in Customer Master
KNB1 --- Customer Master (Company Code Data)
KNVV --- Customer Master Sales Data
MARA --- General Material Data
MARC --- Plant Data for Material
MVKE --- Sales Data for Material
Please Reward If Really Helpful,
Thanks and Regards,
Sateesh.Kandula -
Hello All,
Can anyione help me on this. I am not able to understand what control table changes mean. I know what Table controls are but not known to control table.
And they are different from each other.
Can anyone please help me on this.
Regards
anuhi,
WELCOME TO SDN.
*Control Tables
The search indexes for address data, as well as the address data itself, are client-dependent. There can now be other differentiations within a client. These are called "Index pools".
The division reflects the fact that multiple areas of master data are involved, which differ from the business embedding in the SAP System and from the technical implementation.
Two such index pools are currently defined in table TSADRVGRP with a technical key derived from control table TSADRV:
For More details
http://help.sap.com/saphelp_nw04/helpdata/en/81/23a63a8e1d1e49e10000000a11402f/content.htm
Hope this will help you.
Rewrd points, if found helpful
Regards
ANVER -
Search and move in a control table
Hi guys,
I create a control table that reads a lot of data, so i need to implement a search function.
the easy part is that i can search it in the internal table, my problem is that i need to move the cursor to that position. who do i scroll it?
its dynpro.
any ideas?Hi Javier, Please check this function "SCROLLING_IN_TABLE" and the next code that is generated by wizard
*& Form COMPUTE_SCROLLING_IN_TC
* text
* -->P_TC_NAME name of tablecontrol
* -->P_OK ok code
FORM COMPUTE_SCROLLING_IN_TC USING P_TC_NAME
P_OK.
*&SPWIZARD: BEGIN OF LOCAL DATA----------------------------------------*
DATA L_TC_NEW_TOP_LINE TYPE I.
DATA L_TC_NAME LIKE FELD-NAME.
DATA L_TC_LINES_NAME LIKE FELD-NAME.
DATA L_TC_FIELD_NAME LIKE FELD-NAME.
FIELD-SYMBOLS <TC> TYPE cxtab_control.
FIELD-SYMBOLS <LINES> TYPE I.
*&SPWIZARD: END OF LOCAL DATA------------------------------------------*
ASSIGN (P_TC_NAME) TO <TC>.
*&SPWIZARD: get looplines of TableControl *
CONCATENATE 'G_' P_TC_NAME '_LINES' INTO L_TC_LINES_NAME.
ASSIGN (L_TC_LINES_NAME) TO <LINES>.
*&SPWIZARD: is no line filled? *
IF <TC>-LINES = 0.
*&SPWIZARD: yes, ... *
L_TC_NEW_TOP_LINE = 1.
ELSE.
*&SPWIZARD: no, ... *
CALL FUNCTION 'SCROLLING_IN_TABLE'
EXPORTING
ENTRY_ACT = <TC>-TOP_LINE
ENTRY_FROM = 1
ENTRY_TO = <TC>-LINES
LAST_PAGE_FULL = 'X'
LOOPS = <LINES>
OK_CODE = P_OK
OVERLAPPING = 'X'
IMPORTING
ENTRY_NEW = L_TC_NEW_TOP_LINE
EXCEPTIONS
* NO_ENTRY_OR_PAGE_ACT = 01
* NO_ENTRY_TO = 02
* NO_OK_CODE_OR_PAGE_GO = 03
OTHERS = 0.
ENDIF.
*&SPWIZARD: get actual tc and column *
GET CURSOR FIELD L_TC_FIELD_NAME
AREA L_TC_NAME.
IF SYST-SUBRC = 0.
IF L_TC_NAME = P_TC_NAME.
*&SPWIZARD: et actual column *
SET CURSOR FIELD L_TC_FIELD_NAME LINE 1.
ENDIF.
ENDIF.
*&SPWIZARD: set the new top line *
<TC>-TOP_LINE = L_TC_NEW_TOP_LINE.
ENDFORM. " COMPUTE_SCROLLING_IN_TC
Regards
David N -
Automatic Workflow Customizing - Check entries from HR Control Tables
Hi All
I am preparing the R/3 system before a ESS MSS implementation.
When I execute Transaction SWU3 I have a few red cross marks. Few of those are because the Gateway addresses are not specified and Webserver path is not specified.
The bit that I am worried about is
Check entries from HR Control Tables
SAP Documentation says
*To solve problems of this type, use the report RHTTCP77.
If there are errors regarding the transport objects PDST or PDWS, the relevant entries are not maintained in table SOBJ. You can use the report RHSOBJCH to rectify this later.*
I want to know the implications of correcting the entries with the report RHSOBJCH. Will it affect the configuration which has been done on the system for the business processes?
When I fire off
Consistency Check for Event Linkages
there are a whole bunch of errors which are thrown. Can I Activate/Deactivate the linkages
Wanted to make sure that there will be no knock on effects. Do I need to consider something else regarding these issues?
Thanks in advanceHi Sriram,
I have also faced a similar issue.
Running the mentioned reports did not cause any problem for my case.
Only after running the reports and generating the task was I able to remove the red cross mark.
Regards,
Saumya
Maybe you are looking for
-
anybody here?
-
Thank you for scamming my Grandma and lying to me Verizon.
I recived the cool little upgrade your phone and recive a $100 GIFT CARD!!! It was sent to my number and mine alone, despite I had upgraded to a BB 8 months before. So my grandma decided to get into the world of smartphones. From my expirence BestBuy
-
Error Opening the Database for the library... Aperture 3
I have read many forum entries. I have tried repairing and rebuilding, no success. When I select the library (5.77GB) while pressing Command+Option, It says there is an error opening so the First Aid screen never comes up. Help!!
-
Will there be any issue with Flash running off a laptop form a different country it was developed on? We just want to be able to open the html page and have everything running locally off the laptop. The application was made in USA and the laptops i
-
Library Filter Text not working in LR2
Hi, If i use the library filter for text and set it as "filename" and "contains" w/o entering any characters into the search bar I get 3 images, although I have it set to seach "All Photographs" in the catalog section. Please see screenshot. If I en