‎2006 Dec 12 10:50 AM
Hi all,
my dought in BDC. in BDC we have
perform bdc_dynpro using 'SAPMF02K' '0100'.
perform bdc_field using 'BDC_CURSOR'
'RF02K-KTOKK'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
Could u plz tell me meaning of that & what is the use.
regs,
padma.
‎2006 Dec 12 10:53 AM
HI Padma,
The meaning is the program is trying to place a cursor in the field with the name 'RF02K-KTOKK' in the screen 0100 of the program SAPMF02K and then does a user action(Like clicking a button) which has a function code /00(Probably ENTER).
REgards,
Ravi
‎2006 Dec 12 10:54 AM
Hi,
perform bdc_dynpro using 'SAPMF02K' '0100'.
perform bdc_field using 'BDC_CURSOR'
'RF02K-KTOKK'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
You can see the performs ..the forms for which are defined in the standard include at the top bdcrecx1. here you are passing the data to the form like program name sapmf02k and screen number 0100.and bdc cursor on field rf02k-ktokk
bdc_okcode is the function code for the command field... /00 means means enter
/11 means save like that
mark if helpful.
regards,
pankaj singh
‎2006 Dec 12 10:55 AM
In BDC u will create an internal table of structure BDCDATA which has 5 fields.
<b>Program - pass program name
Dynpro - screen number
Dynbegin - "X'
Fnam - Field name
Fval - Field value</b>
in ur code SAPMF02K is program & 0100 is screen number.
BDC_CURSOR is Fnam & 'RF02K-KTOKK is fval.
u will pass this data to the BDCDATA table.
‎2006 Dec 12 11:20 AM
Hi Padmavathi,
Basically BDC uses recording of a given transaction and then replay of the same with different sets of input data.
So when you record any transaction, the technical details about the transaction are automatically recorded by SHDB transaction. When you transfer this recording detail in to Program, system automatically generate the code.
Now this is the code where all the subroutines will be called related to this recording of transaction. The subroutines are called using PERFORM statement.
E.g. in your example it is PERFORM subroutine_name USING parameter values.
Hence here BDC_DYNPRO & BDC_FIELD are two subroutines. And these subroutines passes values for the defined parameters like Screen Number, Program Name, Whether a new screen has started in recording (Flag), actual values for the fields, the action codes like pressing Save button or pressing Enter key from recording.
For more details about what kind of parameters subroutine uses, just double click on Perform statement and it will take you to FORM - ENDFORM of the same. Here in Form you can see the type of parameters used.
1. PERFORM bdc_dynpro USING 'SAPMF02K' '0100'
Here Subroutine Name - BDC_DYNPRO
SAPMF02K - Program Name (Subroutine Parameter)
0100 - Screen Number (Subroutine Parameter)
2. PERFORM bdc_field USING 'BDC_CURSOR' 'RF02K-KTOKK'.
Here Subroutine Name - BDC_FIELD
BDC_CURSOR - It is subroutine parameter and specifies that the cursor will be now placed on the field of transaction mentioned along with it i.e. RF02K-KT0KK in this example
3. PERFORM bdc_field USING 'BDC_OKCODE' '/00'.
Here Subroutine Name - BDC_FIELD
BDC_OKCODE - Subroutine parameter which specifies the action code along with it. E.g. here it Enter key with code '/00'.
I guess the meaning should be clear to you for all the above fields. The usage is very clear that recording uses this information for relay of the BDC for the given transaction. It will locate the program, the fields and then place the cursor, input the data and do the modification as specified in BDC and then use the action specified like SAVE etc.
Hope this should sort out your query completely.
PS Please reward points to all who responded to help you. And if your query is sorted out, do close the thread.
Regards