10-22-2007 8:18 PM
I want to have a Filter option in my module pool program screen.......
is there any sample code/ program to obtain this functionality....
Message was edited by:
Karthik
10-22-2007 8:25 PM
When the user presses the filter button, you call a popup that has the field that you want to filter. Then you take the value entered and loop at the main internal table and pass only those values that make it through the filter back to the table control.
Rob
10-22-2007 8:26 PM
is there a function module available or do i need to code the logic......
10-22-2007 9:47 PM
this is a specific function module which displays popup's ......for this functionality....
10-22-2007 8:26 PM
Hi,
I don't have sample code, but here is the steps
1. create button in the toolbar as 'Filter"
2. Once user click on this , then call following function modules and get the filter values
* Init free selection dialog
call function 'FREE_SELECTIONS_INIT'
exporting
expressions = i_expr
importing
selection_id = v_selid
expressions = i_expr
tables
tables_tab = i_tables
exceptions
others = 1.
endif.
* Display free selection dialog
call function 'FREE_SELECTIONS_DIALOG'
exporting
selection_id = v_selid
title = 'Selection'
status = 1
as_window = 'X'
importing
expressions = i_expr
field_ranges = i_ranges
number_of_active_fields = v_active
tables
fields_tab = i_fields
exceptions
others = 1.
3. In PBO filter the output table values according to values you are getting out of these above said function module
May this will help you
a®
10-22-2007 9:10 PM
10-22-2007 9:11 PM
10-22-2007 9:31 PM
This filter should exactly as in the alv grid.............
When iam using this fm...getting dump...since no values are passed in the expression,
selection id , ranges etc....
10-22-2007 9:42 PM
I think i did'nt quite communicate the my question...........I have a table control on the screen.....this filter behaves in the same like in ALV grid.........