Dynamically generating Ok_Code for select option of HUMO t-code
Hi Gurus ,
I have used BDC call transaction method in my program to call the HUMO t-code and populating the handling unit in the select option . The ok_code of the select option is written in the program as :
PERFORM bdc_field USING 'BDC_OKCODE'
'=%00120100000003011'.
Now these ok_code value is changing inside the ECC landscape , In all Non-production system the value remains same but in the production system the ok_code value is different , because of this program is successfully executing in non-production but not in production .
If anyone of you have come across situation like this , please help me how to help hold of this ok_code or can we generate in dynamically . For temporary solution i have coded it based on the system like shown below but I am looking for a permanent solution
IF syst-sysid = 'EWP'.
PERFORM bdc_field USING 'BDC_OKCODE'
'=%00120100000003011'.
ELSE.
PERFORM bdc_field USING 'BDC_OKCODE'
'=%00120100000718796'.
ENDIF.
Regards
Anshuman
Hi Gurus ,
I have used BDC call transaction method in my program to call the HUMO t-code and populating the handling unit in the select option . The ok_code of the select option is written in the program as :
PERFORM bdc_field USING 'BDC_OKCODE'
'=%00120100000003011'.
Now these ok_code value is changing inside the ECC landscape , In all Non-production system the value remains same but in the production system the ok_code value is different , because of this program is successfully executing in non-production but not in production .
If anyone of you have come across situation like this , please help me how to help hold of this ok_code or can we generate in dynamically . For temporary solution i have coded it based on the system like shown below but I am looking for a permanent solution
IF syst-sysid = 'EWP'.
PERFORM bdc_field USING 'BDC_OKCODE'
'=%00120100000003011'.
ELSE.
PERFORM bdc_field USING 'BDC_OKCODE'
'=%00120100000718796'.
ENDIF.
Regards
Anshuman
Similar Messages
-
Dynamic variant create for select option High value
Hi ,
I would like to set a dynamic variant for Date filed in selection screen as lower limit as 01/01/2009 and Last day of previous month as hiher limit. For examplae: Lower limit = 01/01/2009 and higher limit as 02/28/2011.
Please help me in creating dynamic variant as mentiond above.
Thanks & Regards,
Venkat N.Hi,
Thank you for your reply and could you please provide if you have any code.
Thanks & Regards,
Venkat N. -
Default Values for Select-options In Webdynpro-ABAP
Hi Freinds,
Kindly,Help me in setting the Default values for the Select-options in Webdynpro ABAP.
Here the Node and the Attributes are Created Dynamically, and then Displayed Select-options Component View.
Regards,
Xavier.PXavier Reddy Penta sent me this question via email and I answered it directly yesterday. Here is the solution that I provided to him, so that it is stored with the original question:
I believe your problem is that you are not setting the value into the range correctly. You are setting it directly into the field symbol of the range like such:
<FS> = L_STRING2.
But ranges are deep objects. They have four fields: Sign, Option, High, and Low. This is from the online help:
1. sign of type c and length 1. The content of sign determines for every row whether the result of the condition formulated in the column is included or excluded in the entire resulting set for all rows. Evaluable values are "I" for include and "E" for exclude.
2. option of type c and length 2. option contains the selection option for the condition of the row in form of logical operators. Analyzable operators are "EQ", "NE", "GE", "GT", "LE", "LT", "CP" and "NP" if column high is initial, and "BT", "NB" if column high is not initial. With the options "CP" and "NP", the data type of the columns low and high must be of the data type c, and special rules apply for entries on the selection screen.
3. low of the data type defined after FOR. This column is designated for the comparison value or the lower interval limitation.
4. high of the data type defined after FOR. This column is designated for the upper interval limitation.
So when you are moving the value into the field symbol you are setting it into the sign column.
Here is an example of how you can access the components of the range:
* create a range table that consists of this new data element
lt_range_table =
wd_this->lv_sel_handler->create_range_table(
i_typename = l_typename ).
IF l_fieldname = 'CARRID'.
FIELD-SYMBOLS: <tab> TYPE INDEX TABLE,
<struct> TYPE ANY,
<wa> TYPE ANY,
<option> TYPE char2,
<sign> TYPE char1,
<high> TYPE ANY,
<low> TYPE ANY,
<wa_values> TYPE ANY.
ASSIGN lt_range_table->* TO <tab>.
APPEND INITIAL LINE TO <tab> ASSIGNING <wa>.
ASSIGN COMPONENT 'OPTION' OF STRUCTURE <wa> TO <option>.
ASSIGN COMPONENT 'HIGH' OF STRUCTURE <wa> TO <high>.
ASSIGN COMPONENT 'LOW' OF STRUCTURE <wa> TO <low>.
ASSIGN COMPONENT 'SIGN' OF STRUCTURE <wa> TO <sign>.
<sign> = 'I'.
<option> = 'EQ'.
<low> = 'AA'.
ENDIF. -
Can i assign a collective srch help for select option in list display
can i assign a collective srch help for select option in list display
Hi,
Yes ,u can assign a collective search help for select-option in list display.
Eg:
Define your select option like this
SELECT-OPTIONS: s_vbeln FOR likp-vbeln MATCHCODE OBJECT vmva.
Regards,
Shiva. -
How to set default values in initialization event for select option
Abapers,
I have 3 GL account like 0024831231,0024831238,0024831245.
Please help me how to set default values in select-options ( s_hkont ) in INTIALIZATION event
ThanksSelect option is table <Structure> with fields, low, high, sign & option
you need to append the value into the select option, with appropriate value in low or
example:
S_HKONT-low = <value>
S_HKONT-SIGN = 'I'
S_hkont-OPTION = 'EQ'
append s_hkont.
Default value for select-option also can be added directly in select-option statement.
Regards,
Mahesh -
Input Negative values in selection screen for select-options field
I am not able enter negative values for
SELECT-OPTIONS V_ERFMG FOR MSEG-ERFMG.
It says negative values are not allowed but I need to check for negative values. Kindly provide me solution.You can't put the negative values here...because the Domain which is attached to MSEG-ERFMG has not the "Sign" checkbox on.
Try with this code:
tables:wbrp.
SELECT-OPTIONS V_ERFMG FOR WBRP-menge.
Regards,
Naimesh Patel -
How to get calender in f4 help for select options in module pool (URGENT)
Hi All,
how to get calender in f4 help for select options in module pool
Please help .
Thanx in advance,
amrutaHi Amruta,
First of all, you can not create select-options directly in module pool.
For creating <b>select-option is dialog prog</b> follow these steps:
1. create your selection screen model as subscreen by:
SELECTION-SCREEN BEGIN OF SCREEN 2000 AS SUBSCREEN.
PARAMETRS: P_MATNR LIKE MARA-MATNR.
SELECT-OPTIONS: S_BISMAT FOR MARA-BISMAT.
SELECTION-SCREEN END OF SCREEN 2000.
2. create a screen ( example 100 ) in your module-pool dedicated for selection-screen. on this screen layout sketch a sub-screen name like subscree_2000.
3. write this bit of code in PBO and PAI of the screen 100;
CALL SUBSCREEN SUBSCREEN_2000.
4. include this code in PBO:
INCLUDING SY-REPID '2000'
6. write user_command of PAI, call screen which is going to executable after selection-screen.
5. create a transcation for this dialog module pool with screen 100.
6. execute this transaction and you can see it's behaving like cool with select-options.
After that in [bprocee on value-request]</b>, use F4_DATE for both from and to option field.
Hope it will solve the problem.
Regards
Krishnendu -
How to assign search help using ovs for select options for ALV in web dynpr
how to assign search help using ovs for select options for ALV in web dynpro
Hi,
refer http://wiki.sdn.sap.com/wiki/display/WDABAP/InputhelpofObjectValueSelectioninWDABAP
http://www.****************/Tutorials/WebDynproABAP/OVS/page1.htm
and http://wiki.sdn.sap.com/wiki/display/Snippets/WebDynproAbap-OVSsearch+help
Thanks,
Chandra -
F4 help for select options based on parameter value
hi all,
I need a help to create an F4 help for select options for object id based on parameter value of object type, I mean once an object type is given the f4 help should contain object id's only of that type for each option.
Regard's,
Girija
Moderator Message : Duplicate post locked. Continue with [f4 help for select options based on parameter value |f4 help for select options based on parameter value;.
Edited by: Vinod Kumar on May 17, 2011 1:36 PMhi all,
I need a help to create an F4 help for select options for object id based on parameter value of object type, I mean once an object type is given the f4 help should contain object id's only of that type for each option.
Regard's,
Girija
Moderator Message : Duplicate post locked. Continue with [f4 help for select options based on parameter value |f4 help for select options based on parameter value;.
Edited by: Vinod Kumar on May 17, 2011 1:36 PM -
How to add OBLIGATORY for SELECT-OPTIONS
Hi experts,
I can use OBLIGATORY for PARAMETERS
PARAMETERS :s_WMno TYPE LINK-LGNUM DEFAULT 'SCA' OBLIGATORY.
I want to add OBLIGATORY for SELECT-OPTIONS. How to do this?
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME .
SELECT-OPTIONS: s_matnr FOR mara-matnr .
SELECTION-SCREEN END OF BLOCK b1.
Many thanks.Hi,
TABLES spfli.
SELECT-OPTIONS : carrid FOR spfli-carrid OBLIGATORY. " This makes only Low field Obligatory
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF screen-name = 'CARRID-HIGH'. " To make High field also obligatory
screen-required = 1.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
Cheerz
Ram -
How to do validations for select-options
Hi gurus,
can you suggest me
how to do validations for select-options
Thanks&ragards,
Kals.HI,
TABLES: BKPF.
TYPES: BEGIN OF TY_BKPF,
BUKRS TYPE BUKRS, "COMPANY CODE
GJAHR TYPE GJAHR, "FISCAL YEAR
MONAT TYPE MONAT, "FISCAL PERIOD
DATA: T_BKPF TYPE TABLE OF TY_BKPF,
W_BKPF TYPE TY_BKPF.
SELECTION-SCREEN : BEGIN OF BLOCK B1 WITH FRAME TITLE TEXT-001.
SELECT-OPTIONS: S_CODE FOR BKPF-BUKRS,
S_YEAR FOR BKPF-GJAHR,
S_PERIOD FOR BKPF-MONAT.
SELECTION-SCREEN: END OF BLOCK B1.
AT SELECTION-SCREEN *
IF S_CODE IS INITIAL OR S_YEAR IS INITIAL OR S_PERIOD IS INITIAL.
MESSAGE E000(0) WITH 'ENTER VLAUES'.
ENDIF.
SELECT SINGLE * FROM BKPF WHERE BUKRS IN S_CODE.
IF SY-SUBRC <> 0.
MESSAGE E000(0) WITH 'ENTER VALID VALUES'.
ENDIF.
reward if useful
thanks and regards -
Standard Match Code for Selection Options with Example
Hi Guys,
Can anybody tell me Standard Match Code or Search help for Selection Options.
ex: MBEW-MATNR , MBEW-BWKEY and MBEW-BWTAR. can anybody tell how to keep Search Help or Match Code for the Above Fields in ECC 6.0 with Example
Very Urgent.
Thanks,
Gopi.Well Gopi.. as per your requirement no need to use collective search help.
I guess you have three fields in selection-screen,out 3 fields you have two fields contains search help.
Create your user defined search help BWTAR ..
Check the below links for creation search help :
http://help.sap.com/saphelp_46c/helpdata/EN/cf/21ee2b446011d189700000e8322d00/frameset.htm
http://help.sap.com/saphelp_nw2004s/helpdata/en/41/f6b237fec48c67e10000009b38f8cf/content.htm
Hope you got it.
Thanks
Seshu -
How to use offset for select-option parameter ?
Hi experts
could anybody please let me know how to use offset for select-option parameter. i can able to use offset for table fields, variabiles and all , but don't know how to use for parameters.
following is my code
SELECT-OPTIONS: s_prctr FOR vbsegs-prctr OBLIGATORY.
here "prctr" length is 10.
i'm using two tables 1. vbsegd-bupla
2. vbsegs-prctr
here prctr+6(4) = bupla.
"Bupla" length is 4
SELECT belnr gjahr bukrs bupla sgtxt buzei FROM vbsegd INTO CORRESPONDING FIELDS OF TABLE it_vbsegd FOR ALL ENTRIES IN it_vbkpf
WHERE belnr = it_vbkpf-belnr
AND gjahr = it_vbkpf-gjahr
AND bukrs = it_vbkpf-bukrs
AND bupla IN s_prctr.
the above statement is not working as prctr and bupla lenths are different. here i want to use offset.
SELECT belnr gjahr bukrs prctr sgtxt buzei FROM vbsegs INTO CORRESPONDING FIELDS OF TABLE it_vbsegs FOR ALL ENTRIES IN it_vbkpf
WHERE belnr = it_vbkpf-belnr
AND gjahr = it_vbkpf-gjahr
AND bukrs = it_vbkpf-bukrs
AND prctr IN s_prctr.
this is working as prctr and s_prctr lengths are equal.
could anybody please help me out in this.
Thanks in advance.
regards
satishBelow code will work for you.
SELECT-OPTIONS: s_prctr FOR vbsegs-prctr OBLIGATORY.
RANGES: s_bupla FOR vbsegd-bupla.
s_bupla[] = s_prctr[].
DELETE ADJACENT DUPLICATES FROM s_bupla.
SELECT belnr gjahr bukrs bupla sgtxt buzei FROM vbsegd INTO CORRESPONDING FIELDS OF TABLE it_vbsegd FOR ALL ENTRIES IN it_vbkpf
WHERE belnr = it_vbkpf-belnr
AND gjahr = it_vbkpf-gjahr
AND bukrs = it_vbkpf-bukrs
AND bupla IN s_bupla. -
Value help for select-option not filling selection field
I'm having some problems with a value help on a select-option. I've managed to get the value help displaying the correct values but for some reason can't get it to populate the selection field after I've selected a record.
I have the following call:
wd_this->m_handler->add_selection_field(
i_id = 'SHORT_D'
i_description = 'Program'
it_result = lt_range_table
i_read_only = read_only
i_value_help_type = IF_WD_VALUE_HELP_HANDLER=>CO_PREFIX_SEARCHHELP
i_value_help_id = 'ZPROGSTUDY' ).
where ZPROGSTUDY is a new search help I've set up with an exit to retrieve the values.
Any ideas ? Thanks.Hi Malcolm,
The code you have is OK. I copied your code into a test program and it worked as expected.
I used a search help where the possible values are populated in the search help exit, exactly as in your case. The only time it did not work was when read_only = X, but that is obvious also from a visual point of view since the input field is greyed out in that case. The popup also tells you is in RO mode...
Does your SHLP work when you test it from SE11? Returns values?
SAP provides a lot of WD4A sample code, see for example component WDR_TEST_SELECT_OPTIONS look for
select-option fields > special cases > input helps > Non field-specific input help using search help
Regards,
George -
Set of default values for Select-Options
Hi Gurus,
I have a requirement where I need to set default values for select options
ex: SELECT-OPTIONS: S_MTART FOR MARA-MTART
default values must be ERSA - HIBE- FHMI - DIEN - GEST
Please tell me how to do it.
Effective replies will be rewarded with full points
KarthikHi,
For each SELECT-OPTION, you can only specify one DEFAULT.
You must specify the default value g in its internal format, e.g. "SELECT-OPTIONS DATE FOR SY-DATUM DEFAULT '19931224'", not "... DEFAULT '24.12.1993'".
The default value g should normally be a literal because, at runtime when you use SUBMIT, it is transferred to the selection options table sel so early that no value can be assigned to the field g. System fields like SY-DATUM are an exception here because the system usually assigns values to them as soon as the report processing starts.
When you use user-defined selection screens in your programs that you do not call using SUBMIT, the DEFAULT value is transfered when the selection screen is first called. In this case, therefore, you can use other fields g.
regards,
sowjanya
Message was edited by: sowjanya suggula
Maybe you are looking for
-
Xy graph in excel using activeX
Hi I am trying to plot a XY graph in excel using Active X. I have two coloums of data one should be X the other should be Y. I am using XlXYscattersmooth graph type and giving the range as A1 to B5. But when the excel plots it, I am getting two serie
-
Proxy to File scenario - CLIENT_RECEIVE_FAILED
Hello, i am working on File to Proxy scenario in which i got the following error message. Can any one help me out.. Message from sxmb_moni: <SAP:Category>XIServer</SAP:Category> <SAP:Code area="INTERNAL">CLIENT_RECEIVE_FAILED</SAP:Code> <SAP:P1>2
-
Can I run AJRW before running the depreciation in the last period. When we try to run a report, we getting error message saying that year end change is not yet made. SAP is not even letting us run the report even for an earlier date. Let me know if c
-
ABAP report using /BIC/ tables
Hi Friends, Have anybody created ABAP reports in BI system using /BIC/ reports & What is the requirement? Please let me know. Thanks in advance, Beena
-
Hey guys! I'm having quite the problem with the OS. Here are some pictures and a video of it in action: Ok for some reason the images look flipped on the website. But anyway, this is recurring everytime I boot up or log off. I have done a reinstal