01-26-2009 10:10 PM
I want to display text right after the selection parameter.
E.g.
P_MATNR TYPE VBAP-MATNR.
Once the user enters the materil number in the parameter and presses enter, the material description
should be display on to the right of the material number.
MV1234 (Material Description) .
Appreciate Help.
01-26-2009 10:58 PM
SELECTION-SCREEN BEGIN OF LINE.
PARAMETER: p_matnr TYPE matnr MODIF ID b.
PARAMETER:p_desc TYPE maktx MODIF ID a.
SELECTION-SCREEN END OF LINE.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF screen-group1 = 'A'.
screen-input = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
SELECT SINGLE maktx
INTO p_desc
FROM makt
WHERE matnr = p_matnr.
Rob got it right....
Edited by: J@Y on Jan 26, 2009 6:00 PM
01-26-2009 10:24 PM
Hi,
Try this..
selection-screen begin of line.
parameters P_MATNR TYPE VBAP-MATNR.
selection-screen comment +40(<size of your text>) text-001(This should contain the description)
selection-screen end of line.
01-26-2009 10:37 PM
Hi Rao,
You can achieve the requirement by declaring two selection screen variables, one for material number and one for material description.
Make sure you make material description as non-editable field. Get help on parameters or select-options which gives all display options.
ON SELECTION SCREEN <material>.
write program lines which populates your selection screen field <material description>.
Best Regards,
Krishna
01-26-2009 10:50 PM
This works:
REPORT ztest LINE-SIZE 80 MESSAGE-ID 00.
TABLES: mara, makt.
PARAMETER: p_mat LIKE mara-matnr OBLIGATORY.
SELECTION-SCREEN COMMENT 54(40) comm01.
AT SELECTION-SCREEN.
SELECT SINGLE maktx FROM makt
INTO comm01
WHERE matnr = p_mat
AND spras = sy-langu.
IF sy-subrc <> 0.
comm01 = 'Invalid material'.
ENDIF.
Rob
01-26-2009 11:10 PM
I am getting the below message when i try to activate.
Error when generating the selection screen "1000" of report "ZTST
01-26-2009 11:14 PM
Your screen must be smaller. You can play with the position of the elements.
Rob
01-26-2009 11:26 PM
01-26-2009 10:58 PM
SELECTION-SCREEN BEGIN OF LINE.
PARAMETER: p_matnr TYPE matnr MODIF ID b.
PARAMETER:p_desc TYPE maktx MODIF ID a.
SELECTION-SCREEN END OF LINE.
AT SELECTION-SCREEN OUTPUT.
LOOP AT SCREEN.
IF screen-group1 = 'A'.
screen-input = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
SELECT SINGLE maktx
INTO p_desc
FROM makt
WHERE matnr = p_matnr.
Rob got it right....
Edited by: J@Y on Jan 26, 2009 6:00 PM