I'm trying to enter the following formula to a range of cells within a macro
=INDEX('[Rest Days.xlsx]Sheet1'!$B$3:$B$26,MATCH("*"&A6&"*",'[Rest Days.xlsx]Sheet1'!$E$3:$E$26,0))
I keep getting a type mismatch error, I think it's something to do with the "" around the &A6" but can't quite figure it out, Can anyone help me please?
""
is just an empty string. If you want to add an actual quote, then you need to use it four times:""""
. (start and beginning of text, second instance as escape character and third one is the actual quote character. – Máté JuhászRange("G5:G14").Formula = "=INDEX(Nights!$B$2:$B$23,MATCH("" * ""&A5&"" * "",Nights!$E$2:$E$24,0))"
– user3598756