I have 3 groups
Group 1 - Org
Group 2 - Center
Group 3 - Loc
Then detail field {amount}
Then i used 'underlay' functionality so its like
Org Center Loc amount
023 VA RN $1332
I have a need to sort the first group based on 2 different
fields {AllocID} and {AllocDet} on Ascending and Descending
based on what parameters user enters.
So basically there is only one parameter and user writes in that parameter,
for ex:
If user writes 'AllocID ASC' in parameter then --- Sort by AllocID in ascending order
If user writes 'AllocID DESC' in parameter then --- Sort by AllocID in Descending order
If user writes 'AllocDet ASC' in parameter then --- Sort by AllocDet in ascending order
If user writes 'AllocDet DESC' in parameter then --- Sort by AllocDet in Descending order
So i created 4 formulas
{@SortAllocIDASC}
==================
If
InStr({?Param},'AllocID ASC')>0
Then
{Table.AllocID}
{@SortAllocIDDESC}
==================
If
InStr({?Param},'AllocID DESC')>0
Then
{Table.AllocID}
{@SortAllocDetASC}
==================
If
InStr({?Param},'AllocDet ASC')>0
Then
{Table.AllocDet}
{@SortAllocDetDESC}
===================
If
InStr({?Param},'AllocDet DESC')>0
Then
{Table.AllocDet}
And i dropped this fields on details section
and then did insert summary (maximum) on each formula
and dropped it on GroupFooter1 i.e., Org
Now used Group sort expert and on 'org' group -> selected 'All' ->
then for formula
{@SortAllocIDASC} -> Ascending
{@SortAllocIDDESC} -> Descending
{@SortAllocDetASC} -> Ascending
{@SortAllocDetDESC} -> Descending
Now when user enters 'AllocID ASC' in parameter field, its not getting sort ascending on AllocID.
Same applies for other 3 formulas, not getting sorted as expectd.
I really need your help guys on this.
Thanks