spaces

N1234

Member
Local time
Today, 11:55
Joined
Jun 22, 2020
Messages
64
Hello again!

I'm currently trying to hyperlink to specific excel worksheet names that have spaces in them. I can get it the hyperlink working without the spaces i.e:
C:\Users\Desktop\Excel.xlsx#Sheet1!A1. But if there's a space between Sheet and 1, i.e: Sheet 1, I can not longer get the hyperlink to work.

I've tried C:\Users\Desktop\Excel.xlsx![Sheet1]!A1 and C:\Users\Desktop\Excel.xlsx#'Sheet 1'!A1 but they both produce errors.

Thanks again for your help!
 
Skip the hyperlink and just write code to open the path when they click somewhere/thing
 
Have you tried C:\Users\Desktop\Excel.xlsx#'" & "Sheet 1" & "'!A1?

Cheers,
 
Whenever a variable contains spaces or non-standard characters, you should enclose the string in double quotes.
Code:
FollowHyperlink  & """" & Me.txtLink & """"
 
so far as I am aware, excel does not allow spaces in range names
 
so far as I am aware, excel does not allow spaces in range names
Sheet names are fine though?
1606911284904.png
 

Users who are viewing this thread

Back
Top Bottom