‎2006 Jul 13 7:38 AM
hi friends,
i am using 3 radiobuttons in a screen, i select first button then display the two fields company code, customer, when i select the 2 radiobutton then display the vendor in place of customer same screen, how to over write vendor in place of customer, give me solution, where its write code in PBO or PAI,
thanks,
santha
‎2006 Jul 13 7:40 AM
make the two parameter one for vendor and another for customer.
when u click radio button activate customer parameter and deactivate vendor vise versa...
‎2006 Jul 13 7:43 AM
Hello,
You have to write a code in PBO.
Take separated fields for the customer and vendor. Give different screen groups for both.
In pbo, code like.
loop at screen.
if screen-group1 = 'GP1' and r_1 = 'X'.
screen-active = 0.
elseif screen-group1 = 'GP2' and r_2 = 'X'.
screen-active = 0.
endif.
modify screen.
endloop.
regards,
Naimesh
‎2006 Jul 13 9:33 AM
Hi
U can do it by 2 ways.
Either declare a field(F1) of type char and say length 15.Put it on your screen.
After choosing 1st button evaluate the fcode in pai and according to that code your select stmt.
For Customer :
select name1
from kna1
into f1
where <condn>.
For vendor :
select name1
from lfa1
into F1
where <condn>.
This is one way for solving this issue. Otherwise declare 2 different fields on screen from LFA1/kna1 if you're taing it from dictionary.
then in PBO loop at screen and modify as per requirement.
Hope this will help u.
With Rgds
Pradipta Ku Mishra
‎2006 Jul 13 9:38 AM
Hello,
U have a write a module in the PBO event.
PBO
Module disp_field.
In the report
Module disp_field.
CAse 'X'.
when 'R1'.
Loop at screen.
if screen-name = 'VENDOR'
screen-invisible = '1'.
screen-visible = '0'.
Modify screen.
endloop.
when 'R2'.
if screen-name = 'CUST'
screen-invisible = '1'.
screen-visible = '0'.
Modify screen.
endloop.
ENDMODULE.
Try with this code.
If useful reward points.
Regards,
Vasanth