Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
how to use match with variables?
in attach a small example with a variable, where if i copy text value it work's but if i intend to use the variable don´t.
cam you help me ?
thanks
Ricardo
That is because your variable contains unquote shortened month names. The $-sign expansion will result in an invalid parameter list.
You could change this into somthing like
=Match('Jan', $(=chr(39) & replace(MonthNames, ';', chr(39) & ',' & chr(39)) & chr(39)))
but that looks overly complex to me...
[Edit] Corrected expression to use MonthNames variable. Works better
That is because your variable contains unquote shortened month names. The $-sign expansion will result in an invalid parameter list.
You could change this into somthing like
=Match('Jan', $(=chr(39) & replace(MonthNames, ';', chr(39) & ',' & chr(39)) & chr(39)))
but that looks overly complex to me...
[Edit] Corrected expression to use MonthNames variable. Works better
Peter,
did not work.
Yes, because your vMonthNames variable already did contain a complex expression. Try again with the amended example...
Ah, this also works well:
=Match('Jan', $(=$(vMonthNames)))
Peter,
works fine.
And now I understand your answer.
thanks