Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

validating input in table maintanence dialog

Former Member
0 Likes
1,057

Hi,

i need to validate entries while entering/changing values in table maintanence dialog based on other values in that record and other entries .i created a custom transaction code to do this.

for eg.

name-number-rank

aaaa-000001--001

bbbb-000002--

if i try to set rank to '001' for the second record it should not allow and should display a message. any inputs.

your help will be rewarded.

Thanks,

venu.

Hi,

i need to validate entries while entering/changing values in table maintanence dialog based on other values in that record and other entries .i created a custom transaction code to do this.

for eg.

name-number-rank

aaaa-000001--001

bbbb-000002--

if i try to set rank to '001' for the second record it should not allow and should display a message. any inputs.

your help will be rewarded.

Thanks,

venu.

4 REPLIES 4
Read only

Former Member
0 Likes
645

Hi

You can read your internal table for that field for a validation.

I suppose you're using a table control

LOOP AT ITAB TRANSPORTING NO FIELDS WHERE RANK = RANK.

if sy-tabix <> <table control>-current_line.

It means there another record with the same value

---> error message

endif.

ENDLOOP

Max

Read only

Former Member
0 Likes
645

Venu,

Go to transaction SE54 and create events for table maintenance. Select the type of event (like whether you want to trigger that while data insertion, modification,deletion etc) according to your need there and write the appropriate code in that event.

Read only

Former Member
0 Likes
645

You don't have to create custom maintenance transaction. Create standard table maintenance using table maintenance generator tool. Use table maintenance <b>events</b> to carry out your edit checks.

Message was edited by: Sharad Agrawal

Read only

Former Member
0 Likes
645

Hi Venu

i assume that you are using SAp generated table maintenance dialog. If so you can follow this way.

1. Find the name of table maintenance dialog program.

Dialog selection input screen --> menu --> system --> status --> find name of program.

2. You edit the table maintenance dialog program in SE80.

3. Edit the particular screen where you want to validate your input.

4. In PAI put your validation code in CHAIN..ENDCHAIN

5. Save & activate the program.

This will work.

Bala

Note: Award points if helpful