Error in search help button at selection-screen
hi all,
i have a small issue.
i have created a seach help button in selection screen .
my code is as bellow.
TYPES: BEGIN OF ty_ZSD_SNID,
KUNNR TYPE KUNNR,
BAREA TYPE WERKS_D,
END OF ty_ZSD_SNID.
DATA : it_z TYPE STANDARD TABLE OF ty_ZSD_SNID.
selection-screen : begin of block b with frame title text-000.
select-options : skunnr for zsd_snid-kunnr.
parameters : pbarea like zsd_snid-barea obligatory.
selection-screen : end of block b.
INITIALIZATION.
SELECT KUNNR BAREA FROM ZSD_SNID INTO TABLE it_z.
SORT it_z BY BAREA KUNNR.
DELETE ADJACENT DUPLICATES FROM it_z COMPARING BAREA KUNNR.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR SKUNNR-low.
IF it_z[] IS NOT INITIAL.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
DDIC_STRUCTURE = ' '
retfield = 'KUNNR' " data base table field name
PVALKEY = ' '
dynpprog = sy-repid " program name
dynpnr = sy-dynnr "screen name
dynprofield = 'SKUNNR-LOW' " layot field name
STEPL = 0
WINDOW_TITLE =
VALUE = ' '
value_org = 'S'
MULTIPLE_CHOICE = ' '
DISPLAY = ' '
CALLBACK_PROGRAM = ' '
CALLBACK_FORM = ' '
MARK_TAB =
IMPORTING
USER_RESET =
TABLES
value_tab = it_z[] " internal talble name
FIELD_TAB =
RETURN_TAB =
DYNPFLD_MAPPING =
EXCEPTIONS
PARAMETER_ERROR = 1
NO_VALUES_FOUND = 2
OTHERS = 3
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
ELSE.
MESSAGE E000(zsdsn).
ENDIF.
my issue is , its working properly if records are there in my z table.
if no records are there in the table then if i do comment the last message statement then its working.
if i do uncomment like the above code, then its dumming.
what i should i do ??
kind regards
closed because of no answer.
Similar Messages
-
How to link a search help to a selection screen field
Hi All,
I am using field PKWRG from PA0017 table in selection screen. I need F4 help there as in Tcode PA30 . But this field does not have value table or check table. However, it has a search help attached 'TRV_PKWRG' .
But, I donot know how to assign a search help to a selection screen field. Please help.
Regards,
NibhaHello,
Fetch all the data which from the table which you want to show in the search help and pass the value to the FM
F4IF_INT_TABLE_VALUE_REQUEST and the selection-screen event must be
at selection-screen on value request parameter or selection option variable.
BCALV_TEST_FULLSCREEN
BCALV_TEST_FULLSCREEN_CALLS
BCALV_TEST_FULLSCREEN_PRINT
BCALV_TEST_FULLSCREEN_STATUS
BCALV_TEST_GRID
BCALV_TEST_GRID_DRAG_DROP
BCALV_TEST_GRID_EDITABLE
BCALV_TEST_GRID_EVENTS
BCALV_TEST_GRID_INDEX
BCALV_TEST_GRID_TOOLBAR
BCALV_TEST_HIERSEQ_LIST
BCALV_TEST_LIST
BCALV_TEST_LIST_PRINT
BCALV_TEST_LIST_STATUS
BCALV_VERIFY_DTYPES_D0100_F01
BCSMENUF01
BDLCOF10
BDLDVI10
BDLTREDF -
F4 search help on report selection screen
Hi to all
I am developing a report.
There are four fields on selection screen.
ncode
ccode
mcode
mj_code
On these fields i want search help.
When I press f4 all possible values should display.
Then in second field, when I press F4 , only the values corresponding to that previous selection should display.
same for remaining two fields also.
Please tell me which function module to use at selection screen and how to select corresponding values only.
Please guide me.
Regards
AnubhavHi Anubhav Gupta,
Try like this code you will definetly get your answer
Parameters: carrid type spfli-carrid,
P_connid(3).
DATA: BEGIN OF values,
carrid type spfli-carrid,
connid type spfli-connid,
END OF values.
data: dinpro_values type table of dynpread,
value_tab like table of values,
field_value like line of dinpro_values.
at selection-screen on value-request for P_connid.
field_value-fieldname = 'CARRID'.
APPEND field_value TO dinpro_values.
CALL FUNCTION 'DYNP_VALUES_READ'
EXPORTING
dyname = sy-repid
dynumb = sy-dynnr
translate_to_upper = 'X'
TABLES
dynpfields = dinpro_values.
READ TABLE dinpro_values INDEX 1 INTO field_value.
values-carrid = FIELD_VALUE-FIELDVALUE.
SELECT CARRID
connid
FROM sflight
INTO TABLE VALUE_TAB
where carrid eq FIELD_VALUE-FIELDVALUE.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'CONNID'
dynpprog = SY-REPID
dynpnr = SY-DYNNR
dynprofield = 'P_CONNID'
value_org = 'S'
TABLES
value_tab = value_tab.
Reward if it is useful only,
Mahi. -
How to limit the search help in the selection screen?
Hi All,
I got a selection option in a selection screen,
say SELECT-OPTIONS KSCHL FOR VAKE-KSCHL.
I want to limit the output list of the search help of this field, e.g. 33 entries for a specific application and usage.
What should I do ?
Thz.Hi,
U can check with these two
<b>... NO-EXTENSION</b>
Effect
The user can only make an entry on one line. Calling the additional "Multiple Selection" screen is not supported and no pushbutton for this appears on the selection screen.
Addition 12
<b>... NO INTERVALS</b>
Effect
The selection option is displayed on the selection screen without a 'to' field. The pushbutton for calling the "Multiple Selection" screen appears immediately after the 'from' field.
This addition thus allows you to generate a simplified display on the selection screen. This is particularly useful if you are not making any range selections for this selection option.
Notes
On the "Multiple Selection" screen, you can also enter ranges for selection options with "NO INTERVALS".
By combining this addition with "NO-EXTENSION", you can restrict the user to entry of a single value for the selection option, but with the possibility of also choosing single value options like 'Greater than' or 'Less than or equal'.
By using the addition " NO INTERVALS" with SELECTION-SCREEN BEGIN OF BLOCK, you can activate the simplified display for all selection options in a block.
The function module SELECT_OPTIONS_RESTRICT allows you to restrict the set of selection options available for a SELECT-OPTION (for example, only single values and patterns, i.e. 'EQ' and 'CP' are allowed). You can also forbid the leading sign 'E' (= 'Exclude from selection'). This means that you can considerably restrict the selections which can be entered on the selection screen.
Just now tried it out to limit the search help u have to use NO-EXTENSION.
<b>Try this simple code.
Tables: mara.
SELECT-OPTIONS: s_matnr FOR MARA-matnr NO-EXTENSION.</b>
Hope this helps.
Kindly reward points and close the thraed if ur problem got solved.
U havent rewarded any points?
Message was edited by: Judith Jessie Selvi -
Attaching a search help to a selection screen "Select-options"
Hello ABAPers,
I have a requirement to attach a search help to "select-options" .
When I checked the table corresponding to the field of select-options,I found that there is no search help assigned for that field.
I have tried using AT Selection-screenON VALUE-REQUEST and Matchcode Object .
However, Matchcode Object requests for standard search help name.
On value-request assign shelp only for the lower linit,but on pressing F4, gives no values found.
Tried using the FM F4IF_INT_TABLE_VALUE_REQUEST also. But this is for the POV event.
Could anyone please suggest a solution for this problem?Hi,
As you are using this Z search help in select options there is no way of interfering with standard SAP table.
You can declare it as:
Select-options QNAME for TQRFCOUT-QNAME matchcode object <Z search help name>. -
Attach search help to a selection screen field
Hi All,
I have a parameter p_kschl like nast-kschl in my selection screen.
My requirement is whenever sales org equals to '3' i need to set p_kschl
default ZE02 and make a picklist available with ZE02 and ZE04 available with the descriptions
How to make that picklist having ZE02 and ZE04 with descriptions.Yes, then you will use a FM like [F4IF_INT_TABLE_VALUE_REQUEST|https://forums.sdn.sap.com/search.jspa?objID=c42&q=F4IF_INT_TABLE_VALUE_REQUEST]
But as this event is in the POV, data may have been changed to screen and not yet in the program, so you will need to use FM [DYNP_VALUES_READ|https://forums.sdn.sap.com/search.jspa?threadID=&q=DYNP_VALUES_READ&objID=c42&dateRange=last90days&numResults=15&rankBy=10001] to get current value of some fields on the screen (sales org.). (and [DYNP_VALUES_UPDATE|https://forums.sdn.sap.com/search.jspa?threadID=&q=DYNP_VALUES_UPDATE&objID=c42&dateRange=last90days&numResults=15&rankBy=10001] if you want to change the current value of another field on screen)
Regards,
Raymond -
Supress 'Further Selection' And 'Search Help' buttons from LDB selection sc
Hi,
How to supress/invisible 'Further Selection' And 'Search Help' buttons from LDB selection screen?
waiting for reply.
Shweta.Hi,
1) try to use another version of sel-screen
2) work with loop at screen:
LOOP AT SCREEN.
CASE SCREEN-NAME.
WHEN 'ANLAGE-LOW' OR 'ANLAGE-HIGH'
OR '%_ANLAGE_%_APP_%-TEXT'
OR '%_ANLAGE_%_APP_%-VALU_PUSH'
OR '%_UNTNR_%_APP_%-TEXT'
OR 'UNTNR-LOW' OR 'UNTNR-HIGH'
OR '%_UNTNR_%_APP_%-VALU_PUSH'
OR 'BEREICH2' OR 'BEREICH3'.
SCREEN-INVISIBLE = 1.
SCREEN-INPUT = 0.
SCREEN-OUTPUT = 0.
WHEN 'BUKRS-LOW'.
SCREEN-REQUIRED = 1.
WHEN OTHERS.
CONTINUE.
ENDCASE.
MODIFY SCREEN.
ENDLOOP.
A. -
Error during creation of push button on selection screen
Hi,
I wanted to create push buttons on selection screen,
Code:
DATA DB1 TYPE VBAP-WERKS.
DATA DB2 TYPE MARA-MATNR.
SELECT-OPTIONS : SPLANT FOR DB1,
SCLASS FOR DB2.
SELECTION-SCREEN: FUNCTION KEY 1,
FUNCTION KEY 2,
FUNCTION KEY 3.
INITIALIZATION.
DATA FUNCTXT TYPE SMP_DYNTXT.
CLEAR FUNCTXT.
DATA: FUNCTXT_01 TYPE SSCRFIELDS-FUNCTXT_01.
FUNCTXT-TEXT = 'DEL'.
SSCRFIELDS-FUNCTXT_01 = FUNCTXT.
CLEAR FUNCTXT.
FUNCTXT-TEXT = 'EDIT'.
SSCRFIELDS-FUNCTXT_02 = FUNCTXT.
CLEAR FUNCTXT.
FUNCTXT-TEXT = 'CRE'.
SSCRFIELDS-FUNCTXT_03 = FUNCTXT.
But during activating, I'm getting the error as : Field "SSCRFIELDS-FUNCTXT_01" is unknown. It is neither in one of the specified tables nor defined by "DATA" statement.
Please suggest solutions to overcome this error.
Regards
Darshan MSHi,
trans. for examples of selection screen : BIBS
regards
Fred -
Creation of search help manually fro select-options
hi friends i got a requirement for creating the search helps manually for select-options.
but i am facing a progbalem.
i am attaching a sample code for what i have written for select-opions low of which when i am pressing f4 button i am getting list of data but when i am selecting that particular it is not withstading on the screen...kindly help in this regard very urguent..plz...all answers are rewarded..
tableS: kna1.
datA: BEGIN OF ITAB OCCURS 1,
KUNNR TYPE KNA1-KUNNR,
END OF ITAB.
data: kunnr type kunnr.
select-options: cust for kunnr .
at selection-screen on value-request for cust-low.
select kunnr from kna1 into table itab .
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
* DDIC_STRUCTURE = ''
RETFIELD = 'CUST-LOW'
* PVALKEY = ' '
* DYNPPROG = ' '
* DYNPNR = ' '
* DYNPROFIELD = ''
* STEPL = 0
* WINDOW_TITLE =
VALUE = 'CUST-LOW'
VALUE_ORG = 'S'
* MULTIPLE_CHOICE = ' '
* DISPLAY = 'X'
CALLBACK_PROGRAM = SY-CPROG
* CALLBACK_FORM = ' '
* MARK_TAB =
* IMPORTING
* USER_RESET =
TABLES
VALUE_TAB = ITAB
* FIELD_TAB =
* RETURN_TAB =
* DYNPFLD_MAPPING =
* EXCEPTIONS
* PARAMETER_ERROR = 1
* NO_VALUES_FOUND = 2
* OTHERS = 3
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.Hai Saslove,
I think Problem Lies In this Area When U r Creating Search Helps.
Import and Export Parameters
When an input help is called, the entries that the user already made in the input template are taken into consideration. For example, if a user calls the input help for the flight number and already specified the carrier, of course only the numbers of flights of this carrier should be offered.
On the other hand, if the user selects one row of the hit list, more than one field of the input template might have to be filled with data from the selected row of the hit list. For example, if the flight number is obtained from the hit list, the city of departure and the destination should also be returned in the screen template.
The interface of a search help defines the context data that can be used in the input help and the data that can be returned in the input template.
A parameter of a search help can be classified as:
Import parameters: Parameters with which context information from the processed input template (screen) may be copied to the help process.
Export parameters: Parameters with which values from the hit list may be returned to the input template.
A parameter can simultaneously be an input and an export parameter. A search help can also contain parameters that are neither import nor export parameters. Such parameters could be required for the internal input help process, for example.
When you attach a search help, you must define where the import parameters of the search help get their values from and the fields in which the contents of the export parameters are returned. See also Value Transport for Input Helps.
Regards.
Eshwar. -
Code for execute button on selection screen to get result
hi experts,
I need a help for writing a code for execution button on selection screen.Like in normal report on abap editor
we insert selection criteria like number and we get the result according that particular number on next screen.
same thing i am trying here also. So i am writing a code on button that when i press the button it will go to the next
screen according to the selection criteria.
Plz help me helpful answers are appriatiated !!!
Thanks & regards
Vipul Guptahi,
In the OnAction write :
1. get the values entered in selection criteria using :
DATA lo_nd_cn_check TYPE REF TO if_wd_context_node.
DATA lo_el_cn_check TYPE REF TO if_wd_context_element.
DATA ls_cn_check TYPE wd_this->element_cn_check.
DATA lv_ca_check LIKE ls_cn_check-ca_check.
navigate from <CONTEXT> to <CN_CHECK> via lead selection
lo_nd_cn_check = wd_context->get_child_node( name = wd_this->wdctx_cn_check ).
get element via lead selection
lo_el_cn_check = lo_nd_cn_check->get_element( ).
get single attribute
lo_el_cn_check->get_attribute(
EXPORTING
name = `CA_CHECK`
IMPORTING
value = lv_ca_check ).
Now lv_ca_check has your value entered in Selection criteria.
2. write the select query to fetch data according to selection criteria.
select * from <table> into correponding field of table <internl table>
where Field = lv_ca_check.
3. Now in the internal table <internl table> you have values according to search criteria.
4. Bind the internal table with node which is binded to table to show data.
lo_nd->bind_table( internaltable ).
I hope it is clear . -
Use search help to populate two screen fields
I've done a search on this and see that plenty of people ask this question but none get answers, hopefully you'll be able to help me out.
I have a selection screen with two fields:
data: s_house LIKE t012k-hbkid,
s_account LIKE t012k-bankn.
I've created my own search help Z99FI_BANKN and attached it to field s_account. The search help has two fields:
BANKN - IMP, EXP
HBKID - IMP, EXP
If I click on F4 in field s_account and select an account, it populates s_account but not s_house. Can someone tell me where I'm going wrong? I'd like the one search help, when I select an account on field s_account to populate s_house too.
Thanks,
GillGill,
Try the following.
First of all in your top include define your structure:
TABLES: Z99FI_T012K.
Second, open your structure, select BANKN, select the tab Entry help/check
and press the button Search Help. There you must match the fields from your structure with your search help parameters.
In my case it was:
ZLOAD_DESCR ZZLOAD ZLOAD_DESCR
ZLOAD_ID ZZLOAD ZLOAD_ID
Also make sure that in your search help the field you are selecting on is checked as import and export and the field where the data must come along is checked as Export.
Now open up the graphical screen painter, and put on your screen
the fields from your structure. You can do this by opening the window Dictionnary / Program Fields window -> give in the name of your structure and press "Get from dictionary".
Place your fields on your screen, activate it and try again.
Thanks for your feedback on this.
Reward points if helpfull.
Best regards,
Tom. -
One search help for multiple select-options in webdynpro abap
Hi,
I need a way to use one search help for multiple select-options fields. My scenario is :
I have a table for keeping different organizational units' values of different systems. I have pasted some sample data from this table at the end of this mail. On the screen I want to have 1 select-options filed for werks, and 1 select-options filed for vkorg. (In fact I will have more org. unit fields...) In the beginning of my application the user will select sid.
If the user selects ADS as SID, when he opens search-help for the first org. unit (werks), he will see the records with SID: ADS, VARBL = $WERKS, LANGU = SY-LANGU.
If the user selects AGT as SID, when he opens search-help for the second org. unit (vkorg), he will see the records with SID: AGT, VARBL = $VKORG, LANGU = SY-LANGU.
I have created a search-help taking SIDD, VARBL and LANGU as import parameters; used field mapping and bound this search help to my table. I have created 2 context nodes : org1 and org2 having attributes SID, VARBL, VALUE, LANGU .
I have assigned related SID, VARBL and Langu values to these attributes at runtime as I needed. That way, if I use input field and reference to the related context attributes org1-value and org2-value2 accordingly, search help works well as I want.
However, when I use select-options field , I can not bind the field to the context data. I can give reference only to ddic structure. Is there any way to reference to a context attribute? I searched for this in SDN, but could find nothing.
I think I won't be able to use this way. What do you say?
As I read from forums maybe using OVS help will be suitable for me. But I have to use one search-help for all select-options fields. Do you know how I can determine the active select-options field and pass its name (for instance "werks" ) as parameter to this OVS search help. (Also I'll pass SID and LANGU.)
MY TABLE (ZBYYT080) CONTENTS:
SID VARBL VALUE LANGU VTEXT
ADS $WERKS 1 T Werk 0001
ADS $WERKS 11 T OZYAS GIDA URETIM YERI
ADS $WERKS 5501 T BOYA GEBZE FABRİKASI
ADS $WERKS 5502 T BOYA CIGLI FABRİKASI
AGT $WERKS 2301 T KAMLI DAMIZLIK
AGT $WERKS 9601 T PANAR DENIZ URETIM YERI
ADS $VKORG 22 T AA KİMYASALLAR
ADS $VKORG 8001 T İINSAAT BOYALARI
AGT $VKORG 6500 T DAMk St.Org
AGT $VKORG 5400 T PANAR St.Org.
I wish I'm clear enough..
I will be gald if someone answers me as soon as possible...
Thanks İn advance..
MERALHi,
Your ques is how to refer to a DDIC search help to refer to selection screen parameter ?
Am I right ?
If Yes, then in the interface IF_WD_SELECT_OPTIONS
method ADD_SELECTION_FIELD, ADD_PARAMETER_FIELD etc
have importing param like I_VALUE_HELP_TYPE and I_VALUE_HELP_ID, I_VALUE_HELP_MODE, I_VALUE_HELP_STRUCTURE
etc which may help you to link your create DDIC Search help to selection screen params.
this is just a clue from my side. I haven't tried it myself.
You can go to the where used list of this method and find some sample implementations which use these params.
Hope this helps.
Regards
Manas Dua -
F4 Help for the selection screen field
Hi Gurus,
I have to display F4 help for a selection screen field. i am using following code:
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'CODE'
dynpprog = lw_repid
dynpnr = sy-dynnr
VALUE_ORG = 'S'
TABLES
value_tab = gi_text
field_tab = li_fields_tab
return_tab = pi_return_tab
EXCEPTIONS
parameter_error = 1
no_values_found = 2
OTHERS = 3.
My internal table gi_emp has two fields CODE & TEXT. When i select 1 particular value, it returns the CODE value in the pi_return_tab table.
But my requirement is i have to capture the corresponding TEXT value for the Returned CODE. Ex: following is the F4 help being displayed: -
001 test
001 test1
but is i select code 001(First Value), i also need to capture it's corresponding Text value. In return table pi_return_tab i have only Code value.
Please help me out.
Note: Based on return code i can't search into the internal table gi_code, because as shown in the example, code has multiple text.Sachin,
I think this is what you need. The following code will return the key and the text (OR any other columns), if both columns are in the selection screen the selected values (both columns) will also be passed to the corresponding parameters. If you only need the text to be in the return table and not passed to the selection screen then set the parameter for text with NO-DISPLAY option.
REPORT zktest01 .
DATA :
BEGIN OF value_tab OCCURS 0,
field LIKE e070-trkorr,
text LIKE e07t-as4text,
END OF value_tab.
DATA: t_fldtab LIKE dfies OCCURS 0 WITH HEADER LINE,
t_rettab LIKE ddshretval OCCURS 0 WITH HEADER LINE,
t_dynmap LIKE dselc OCCURS 0 WITH HEADER LINE.
PARAMETERS : p_field LIKE value_tab-field,
p_text LIKE value_tab-text. "NO-DISPLAY.
INITIALIZATION.
t_fldtab-tabname = 'VALUE_TAB'.
t_fldtab-fieldname = 'FIELD'.
t_fldtab-langu = 'E'.
t_fldtab-position = 1.
t_fldtab-offset = 0.
t_fldtab-fieldtext = 'Key'.
t_fldtab-reptext = 'Key'.
t_fldtab-leng = 20.
t_fldtab-intlen = 20.
t_fldtab-outputlen = 20.
t_fldtab-datatype = 'CHAR'.
t_fldtab-inttype = 'C'.
t_fldtab-headlen = 20.
t_fldtab-keyflag = 'X'.
t_fldtab-lowercase = ' '.
APPEND t_fldtab.
t_fldtab-tabname = 'VALUE_TAB'.
t_fldtab-fieldname = 'TEXT'.
t_fldtab-position = 2.
t_fldtab-offset = 20.
t_fldtab-fieldtext = 'Text'.
t_fldtab-reptext = 'Text'.
t_fldtab-leng = 60.
t_fldtab-intlen = 60.
t_fldtab-outputlen = 60.
t_fldtab-headlen = 60.
t_fldtab-keyflag = ' '.
t_fldtab-lowercase = ' '.
APPEND t_fldtab.
value_tab-field = '101'.
value_tab-text = 'dddd'.
APPEND value_tab.
value_tab-field = '202'.
value_tab-text = 'aaaa'.
APPEND value_tab.
t_dynmap-fldname = 'FIELD'.
t_dynmap-dyfldname = 'P_FIELD'.
APPEND t_dynmap.
t_dynmap-fldname = 'TEXT'.
t_dynmap-dyfldname = 'P_TEXT'.
APPEND t_dynmap.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR p_field.
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
retfield = 'FIELD'
dynpprog = 'ZKTEST01'
dynpnr = '1000'
dynprofield = 'P_FIELD'
value_org = 'S'
TABLES
field_tab = t_fldtab
value_tab = value_tab
return_tab = t_rettab
dynpfld_mapping = t_dynmap
EXCEPTIONS
parameter_error = 1
no_values_found = 2
OTHERS = 3.
IF sy-subrc EQ 0.
ENDIF.
START-OF-SELECTION.
Jeffrey Satriadi -
F4 help in the selection screen from a int table
I collected the datas from the function module. and the internal table is populated.
the internal table contains manny fields.
among these fields i need to take only one field and this field value to be used for F4 help in the selection screen ( not a dynpro)
for example : in the selection screen
I have to select the PO.
based on the user i have filtered the PO. (determined dynamically by using the user name this i have done it)
then i have to assign the PO the selection screen.
which FM will be better to use for this type of scenario and help me out with some example codes particularly for my req
ThanksHi ,
use the FM 'F4IF_INT_TABLE_VALUE_REQUEST'
This example is for search help for material type .
AT SELECTION-SCREEN ON VALUE-REQUEST FOR s_mtart-low .
select all material types you want to display in search help into table i_mtart.
PERFORM select_material_type.
PERFORM help_material_type.
*& Form help_material_type
text
--> p1 text
<-- p2 text
FORM help_material_type .
CALL FUNCTION 'F4IF_INT_TABLE_VALUE_REQUEST'
EXPORTING
DDIC_STRUCTURE = ' '
retfield = 'MTART'
PVALKEY = ' '
dynpprog = sy-cprog
dynpnr = sy-dynnr
dynprofield = 'S_MTART-LOW'
STEPL = 0
WINDOW_TITLE =
VALUE = ' '
value_org = 'S'
MULTIPLE_CHOICE = ' '
DISPLAY = ' '
CALLBACK_PROGRAM = ' '
CALLBACK_FORM = ' '
MARK_TAB =
IMPORTING
USER_RESET =
TABLES
value_tab = i_mtart
FIELD_TAB =
RETURN_TAB =
DYNPFLD_MAPPING =
EXCEPTIONS
parameter_error = 1
no_values_found = 2
OTHERS = 3
IF sy-subrc 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ENDIF.
ENDFORM. " help_material_type
Regards,
Balaji. -
How to Add Push Button On Selection Screen
Hi Experts,
How to add Push button on Selection Screen.
Points will b rewarded for useful help.
Bohra.Hi,
To create a pushbutton on the selection screen, you use:
SELECTION SCREEN PUSHBUTTON [/]<pos(len)> <push>
USER-COMMAND <ucom> [MODIF ID <key>].
The [/]<pos(len)> parameters and the MODIF IF addition have the same function as for the formatting options for underlines and comments.
<push> determines the pushbutton text. For <push>, you can specify a text symbol or a field name with a maximum length of eight characters. This character field must not be declared with the DATA statement, but is generated automatically with length <len>. The field must be filled before the selection screen is called.
For <ucom>, you must specify a code of up to four characters. When the user clicks the pushbutton on the selection screen, <ucom> is entered in the UCOMM of the SSCRFIELDS interface work area. You must use the TABLES statement to declare the SSCRFIELDS structure. The contents of the SSCRFIELDS-UCOMM field can be processed during the AT SELECTION-SCREENevent.
Ex.
REPORT DEMO.
TABLES SSCRFIELDS.
DATA FLAG.
SELECTION-SCREEN:
BEGIN OF SCREEN 500 AS WINDOW TITLE TIT,
BEGIN OF LINE,
PUSHBUTTON 2(10) BUT1 USER-COMMAND CLI1,
PUSHBUTTON 12(10) TEXT-020 USER-COMMAND CLI2,
END OF LINE,
BEGIN OF LINE,
PUSHBUTTON 2(10) BUT3 USER-COMMAND CLI3,
PUSHBUTTON 12(10) TEXT-040 USER-COMMAND CLI4,
END OF LINE,
END OF SCREEN 500.
AT SELECTION-SCREEN.
CASE SSCRFIELDS.
WHEN 'CLI1'.
FLAG = '1'.
WHEN 'CLI2'.
FLAG = '2'.
WHEN 'CLI3'.
FLAG = '3'.
WHEN 'CLI4'.
FLAG = '4'.
ENDCASE.
START-OF-SELECTION.
TIT = 'Four Buttons'.
BUT1 = 'Button 1'.
BUT3 = 'Button 3'.
CALL SELECTION-SCREEN 500 STARTING AT 10 10.
CASE FLAG.
WHEN '1'.
WRITE / 'Button 1 was clicked'.
WHEN '2'.
WRITE / 'Button 2 was clicked'.
WHEN '3'.
WRITE / 'Button 3 was clicked'.
WHEN '4'.
WRITE / 'Button 4 was clicked'.
WHEN OTHERS.
WRITE / 'No Button was clicked'.
ENDCASE.
This example defines four pushbuttons on a selection screen that is displayed as a
dialog box. The selection screen is defined in a statement chain for keyword
SELECTION-SCREEN.
If the text symbols TEXT-020 and TEXT-040 are defined as 'Button 2' and 'Button 4',
the four pushbuttons appear as follows on the selection screen displayed as a dialog box.
Regards,
Bhaskar
Maybe you are looking for
-
Error while executing the iBot
Hi, I have configured Scheduler on Unix box. I am able to create an iBot and save it but its not executing it when i check the iBot log i can seen the below error iBot Chain Started. Scheduler iBot Version: 201 Job ID: 23 Instance ID: 139.000000 User
-
Version 9,0,3 (15) of iTunes asking for a new version of Safari !
I uploaded the new version of iTunes but since I can not connect to the Store, iTunes is asking for Safari 4.0.3 when I have Safari 3.1.2. I am on Mac OS 10.4.8 and when I upgrade all the software, this version 4.0.3 of Safari is never proposed. Is 4
-
Hello All, please help me to increase memory. I found many answer how it do on OAS 10.1.3 but I'can't find how it do on OC4J Standalone. I have'n opmn.xml file to increase memory. Please give me advice or solution. Thank you.
-
BAPI_SAESORDER_CHANGE in simulation mode
I am using BAPI_SALESORDER_CHANGE to change pricing date and therefore the price for a list of sales items. This is working correctly when I commit the results of the change. However, what I really need to do is first run in simulation mode to obtain
-
Keyboard and Cursor don´t work
Hi, my MacBook Pro has some problems after installing Leopard. the cursor is reacting quite slowly (like the keyboard). Sometimes it takes almost one minute until the cursor is moving. Will 10.5.1 solve the problem?