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

Table control in Module pool

Former Member
0 Likes
700

Hi,

I have created a screen using Table control Wizard. While created I used an Internal table.

Some of the fields in this internal table should have values selected only from respective check table and should not take any other data.

How do I do this ?

Ex: i_tab-kunnr field should have values selected from KNA1-kunnr only. And when this field is selected from screen, a screen should display values and when selected it should be assigned to this field in screen.

Regards

Sudhaker

6 REPLIES 6
Read only

Former Member
Read only

Former Member
0 Likes
660

Hi,

if you are declaring this filed in the screen as the check table field it will solve your problem.

(or).

you can put the validation also for the value of that filed, what ever values your are entering.

Read only

Former Member
0 Likes
660

hi,

have you assigned a check table for your field in table control in screen attributes.

if not you can assign the check table in screen attributes. it will solve your problem. and it will give a list of possible values from the same check table also.

Read only

Former Member
0 Likes
660

Hi Sudhaker,

For fetching values...

We can use a process on value request (POV) for the field in PAI

and manually populate it

process on value-request.

field internaltable-XXXX module f_get_f4.

in the subroutine fill the F4 with the data we need as restricted and use a

F4IF_INT_TABLE_VALUE_REQUEST to poulate data on pop up F4

For Validation....we can always do a check in the chain..endchain of PAI for the field

***********PAI

loop at internal table.

chain.

field: internaltable-XXXX..

module f_check_field on chain-request.

endcahin.

modify _data.

endloop.

in subroutine we can check if value is present or not in the main table with a direct select:eg:

if internaltable-field is not initial.

select single XXX from tbale where XXX = internaltable-field.

if sy-subrc <> 0.

Message 'Value not maintained in table ' type 'E'.

endif.

endif.

Hope it helps

Regards

Byju

Read only

former_member203501
Active Contributor
0 Likes
660

hi look at this..

get the screen elements from the button get fields from the button then assign these values to the fields on the screen.

Read only

Former Member
0 Likes
660

Answered by people in forum. Check thread