Hi Venkat,
Let me know if you are using the Container to create the Alv and using class CL_GUI_ALV_GRID.
If yes , then you can use the method GET_FILTER_CRITERIA to read the variant details.
CALL METHPD GRID1->GET_FILTER_CRITERIA
Importing ET_FILTER = GT_FILTER.
Field "Fieldname" of internal table GT_FILTER has the name of the field on which filter has been applied in variant and then there are filter values under fields "SIGN" "OPTION" "Low" "HIGH".
Using these details you can filter the records from the internal table that you passed to display ALV.
Or
There is another method GET_FILTERED_ENTRIES of class CL_GUI_ALV_GRID which can give you the entries that have been removed after applying the variant.
Based on that you can get the entries that are displayed.
OR
Use the FM : REUSE_ALV_GRID_LAYOUT_INFO_GET and Importing attribute ET_FILTERED_ENTRIES would give you the result.
Thanks
Deepak Sharma