Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
i want to display the current selection in text box. i tried Getcurrentselection(Agency_Name) = 'Selected '
this is my field
List Box
Agency_Name
abc
bcd
cde
def
efg
so when i select an agency it should display me as Agency Selected in a text box
If you use GetCurrentSelections(), you do not specify filed, it shows all fields selections.
For one field, use GetFieldSelections(Agency_Name)
Do you want to append ' Selected' to the list of selected agencies?
Then use the string concatenation operator &:
=GetFieldSelections(Agency_Name) & ' Selected'
you might also want to make sure that if there is no value selected the text does not appear.
another expression u could use
=if(isnull(getfieldselections(Agency_Name))<>-1, 'Agency Selected: ' & getfieldselections(Agency_Name))
GetFieldSelections() will return a string that look like in the current selections object. This means that it will look like the actual search string, if your seleciton is search based. It will also turn into "9 of 152" format when you select multiple values and the seleciton string is too long to display.
If you want to show the actual selected or posible values in the text object, you need to use Concat() function instead.
=Concat(DISTINCT Agency_Name, ', ')
If you only want to show the values when there is a selection you need to find a logic for that.
=If(Len(GetFieldSelections(Agency_Name)), Concat(DISTINCT Agency_Name, ', '), '')
You can replace
IsNull(GetFieldSelections(Agency_Name))<>-1
with
Not IsNull(GetFieldSelections(Agency_Name))