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

Define Ranges on Selection screen

Former Member
0 Likes
824

Hi All,

I have a requirement to define company code as ranges on the selection screen, and then I have loop thru those company codes to get the plants. Any idea how I can define ranges and then use it in the program?

Sample code will be really helpful.

Thanks,

David.

1 ACCEPTED SOLUTION
Read only

suresh_datti
Active Contributor
0 Likes
784

data w_bukrs type bukrs.

select-options: s_bukrs for w_bukrs.

~Suresh

6 REPLIES 6
Read only

suresh_datti
Active Contributor
0 Likes
785

data w_bukrs type bukrs.

select-options: s_bukrs for w_bukrs.

~Suresh

Read only

0 Likes
784

Hi Suresh,

Thanks for a prompt reply. If we define w_bukrs as structure it can take only 1 value right?. They want to enter a range like t001 to t010 and basically I will have to loop thru them. Can u be a little more elaborate how I can use it in program?.

Thanks,

David.

Read only

0 Likes
784

S_BUKRS is the itab that will hold multiple values..

w_bukrs is only for type reference .

~Suresh

Read only

former_member194669
Active Contributor
0 Likes
784

Hi,


selection-screen begin of block 1 with frame title text-100.
select-options : s_ccode for t001-bukrs.
selection-screen end of block 1.

aRs

Read only

Former Member
0 Likes
784

Retrieve the valid company codes from T001 using the range and use these to validate the plants.

Rob

Read only

0 Likes
784

Hi Rob,

My question is when we define ranges for say sompany code, how can I process those ranges in my program..Any sample code would be appreciated

Thanks,

David.