2009 Feb 05 7:27 PM
Hi All, I need to create a Table mantainence in which if one entry is selected for a field say field1 the i have to restrict the other field (field2) entry values in drop down with respect to field1. I have looked at the events but none of the event looks to me is not suitable to my situation. Please let me know if this can be done with the hlep of any event.
Thank You,
Regards,
Swaroop Patri
2009 Feb 07 8:10 AM
Instead of looking for standard table maintenance events u can try and write code in PBO PAI of the maintenance screen itself.
кu03B1ятu03B9к
2009 Feb 05 7:45 PM
Hi,
you can set the type for the field1 as listbox visible length <n> user-comman <okcode>.
so once you select a value in the field1, at selection-screen event gets trigerred and there you can set the value of field2.
another way to acheive the same is
use
at selection-screen of value-request for field2.
write the code....
hope this is clear...
Regards,
Siddarth
2009 Feb 06 1:33 AM
Hi Sidharth, I am actually looking for any events that SAP provides when creating a Table Maintenance.
Regards,
Swaroop Patri
2009 Feb 06 1:46 AM
Hi,
Refer to this link...
[HOW TO IMPLEMENT EVENTS IN TABLE MAINTENANCE|https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/8129f164-0a01-0010-2a8e-8765287250fc]
2009 Feb 06 10:57 AM
hi,
use t code : se30
so that u can enter any number of fields.
with regards,
sumanth reddy
2009 Feb 06 11:59 AM
Hi,
Hi check this code you will get the output.Just copy and execute it...
Definiteli u will get the output
You will come to know that how to do the selection-screen on field validations..
If u use
at selection-screen on field event it will automatically de-highlight the other field..once u enter the value in the first field..Then the next field will be ready to be input...
execute the below code......
DATA:
w_str(52) TYPE c VALUE
*'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ',
w_str(36) TYPE c VALUE '0123456789+-*/!@#$%^&()_=><.?":;|{},'.
SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE one.
PARAMETERS:
p_date LIKE sy-datum MODIF ID gr1,
p_uname TYPE sy-uname MODIF ID gr1.
SELECTION-SCREEN END OF BLOCK b1.
----
Frame for Details of the Employee *
----
SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE two.
PARAMETERS:
p_fname(10) TYPE c MODIF ID grp,
p_lname(10) TYPE c MODIF ID grp,
p_id(6) TYPE c MODIF ID grp.
SELECTION-SCREEN END OF BLOCK b2.
INITIALIZATION.
p_date = sy-datum.
one = 'Login Screen'.
two = 'Student Details'.
"----
AT SELECTION-SCREEN OUTPUT EVENT *
"----
AT SELECTION-SCREEN OUTPUT.
IF p_uname NE sy-uname.
LOOP AT SCREEN.
IF screen-group1 EQ 'GRP'.
screen-active = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ELSE.
LOOP AT SCREEN.
IF screen-group1 EQ 'GR1'.
screen-input = 0.
MODIFY SCREEN.
ENDIF.
ENDLOOP.
ENDIF.
"----
AT SELECTION-SCREEN ON FIELD EVENT
"----
AT SELECTION-SCREEN ON p_uname.
PERFORM validate_uname.
&----
*& Form validate_uname
&----
text
----
--> p1 text
<-- p2 text
----
FORM validate_uname .
IF p_uname NE sy-uname.
MESSAGE 'Invalid User' TYPE 'E'.
EXIT.
ENDIF.
ENDFORM. " validate_uname
"----
AT SELECTION-SCREEN ON BLOCK EVENT
"----
AT SELECTION-SCREEN ON BLOCK b2.
PERFORM validate_details.
*&----
*
*& Form validate_details
*&----
*
text
*----
*
--> p1 text
<-- p2 text
*----
*
FORM validate_details.
IF p_fname EQ space OR p_lname EQ space OR p_id EQ space.
MESSAGE 'Please fill all the Fileds' TYPE 'S'.
ELSE.
IF p_fname CA w_str OR p_lname CA w_str.
MESSAGE 'Only Characters Allowed in Name Fields' TYPE 'S'.
ELSE.
MESSAGE 'Thank you,Press F8 to View the Details' TYPE 'S'.
ENDIF.
ENDIF.
ENDFORM. " validate_details
*start-of-selection.
"----
END-OF-SELECTION EVENT *
"----
END-OF-SELECTION.
IF p_fname IS INITIAL OR p_lname IS INITIAL OR p_id IS INITIAL.
MESSAGE 'Please Fill all the Fields' TYPE 'S'.
ELSE.
IF p_fname CA w_str OR p_lname CA w_str.
MESSAGE 'Only Characters Allowed in Name Fields' TYPE 'S'.
ELSE.
WRITE:/'User Name :', sy-uname,
/'First Name :', p_fname,
/'Last Name :', p_lname,
/'Employee ID :', p_id.
ENDIF.
ENDIF.
Regards
Kiran
Edited by: Kiran Saka on Feb 6, 2009 1:00 PM
2009 Feb 07 6:50 AM
Hi Swaroop,
http://help.sap.com/saphelp_nw04/helpdata/EN/16/4b3c8c170e11d6999d00508b6b8b11/content.htm
check with this link
Redards,
Neelima.
2009 Feb 07 8:10 AM
Instead of looking for standard table maintenance events u can try and write code in PBO PAI of the maintenance screen itself.
кu03B1ятu03B9к
2009 Feb 16 9:48 AM
2009 Feb 16 2:07 PM
Hi,
There is no Event provided for doing what you want to achieve as per your problem description.
Only way to solve this is as suggested by Kartik, do your own programming on value request Or on request in PAI event of your FG generated by SAP.
However if you regenerate FG again in future you need to re-program your changes again.
And seeing so many good replies from experts, i wonder if they understand what you are asking!
Regards
-Bin
2009 Feb 26 12:47 AM
There are No Standard Events for this. I have modified the Code .
Thank You for all your replies
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |