‎2008 Jul 30 7:42 AM
Dear Guru's,
Consider I have 4 fields in a table in a table PA(Personel Area) PSA(Personnel Sub Area) PAText PSAText.... Now I create a Table Maintainace generator for this table using Utilities --> Table Maintainace Generator.
My Requirement is that then i enter PA and PSA values the text must automatically be populated.
Can anyone help me out on this...
Regards
Karthik
‎2008 Jul 30 7:46 AM
Hi,
Use table maintenance generator events for this.
Open ur table. Utilities=>Table maintenance generator=>Environment=>Modifications=>Events.
Here create event 05. It creates 2 forms. Put ur code to populate the text.
eg: Select fields from dbtab INTO ztable-text.
Save and activate. Now if u go to table maintenance and enter PA and PSA values the text will automatically be populated.
Thanks,
Vinod.
‎2008 Jul 30 7:46 AM
Hi,
Use table maintenance generator events for this.
Open ur table. Utilities=>Table maintenance generator=>Environment=>Modifications=>Events.
Here create event 05. It creates 2 forms. Put ur code to populate the text.
eg: Select fields from dbtab INTO ztable-text.
Save and activate. Now if u go to table maintenance and enter PA and PSA values the text will automatically be populated.
Thanks,
Vinod.
‎2008 Jul 30 7:59 AM
Hi,,,
Can you alsotell me how to create the routine..
Regards
Karthik
Edited by: Karthik SP on Jul 30, 2008 8:59 AM
‎2008 Jul 30 9:46 AM
Hi,
U no need to create the routines. Once u give the event number and save it automatically creates the routines. Only u have to put the code in those routines.
Use event 05 if it is new entry,
U can use events 01 and 02 as well.
eg:
If u give 05 and save u can see AT_NEWENTRY in form routine colum. Just click on code icon in Editor column(Next column). It will go to routine. Here place the code.
Check belwo example to populate material description based on material number.
form at_newentry.
SELECT SINGLE MAKTX
from MAKT
INTO ZSD_CRITIC-PROD_DESC
WHERE MATNR EQ ZSD_CRITIC-PROD_ID
AND spras EQ 'E'.
endform.
This populates description to the maintenance view when u enter material number and press enter.
Hope it is clear.
Thanks,
Vinod.
‎2008 Jul 30 9:54 AM
Thanks Guys....
I have rewarded points to all you guys.....
All of you were very helpfull
Regards
Karthik
‎2008 Jul 30 8:09 AM
Hi Friend,
Please go to that path, give the form name and press enter. Now click on the icon beside the form name, it will ask for new include press enter (include will be created in the same function group of TMG). You can write code there.
Hope it will help you.
Regards
Krishnendu
‎2008 Jul 30 8:39 AM
Karthik,
it has to be done in at event 1 (Save data).
http://help.sap.com/saphelp_nw04/helpdata/en/91/ca9f0ea9d111d1a5690000e82deaaa/content.htm
Amit.