Hi guys,
I have the following problem:
I have a listbox (DIM) with about 30 values, for example 'WPOO', 'HWGR', 'UWGR', 'WG'.
I want to display a dimension in a chart only if the value in the listbox is selected.
So for the dimension "HWGR" i have tried it with
=substringcount(Chr(39) & GetFieldSelections(DIM,Chr(39)&','&Chr(39),30) & Chr(39),'HWGR')=1
That works, my problem is, if i do this for "WG" with
=substringcount(Chr(39) & GetFieldSelections(DIM,Chr(39)&','&Chr(39),30) & Chr(39),'WG')=1
the dimension "WG" is shown, even if only "HWGR" is selected.
Is there a chance to do this, for example with match or wildmatch?
Thanks for your answers!
Regards
Chris
Hi Marcus,
thanks for your quick answer.
Yes i thought about this solution also, but now i got it worked myself with this formula:
substringcount(chr(33)&GetFieldSelections(DIM,Chr(33)&','&chr(33),50)&chr(33),'!WG')=1
You may simplify your approach by using a numeric comparison. Means each dim-value get a number, for example with a dual(string, number) or as an extra field created with recno(), rowno(), autonumber() or further methods. And then the comparison may look like: max(Dim) = 5
- Marcus
Hi Marcus,
thanks for your quick answer.
Yes i thought about this solution also, but now i got it worked myself with this formula:
substringcount(chr(33)&GetFieldSelections(DIM,Chr(33)&','&chr(33),50)&chr(33),'!WG')=1