Alex Gordon
Alex Gordon

Reputation: 60841

why should i use single quotes for application.run in excel?

i have this:

Application.Run ("'L:\database\lcmsmacro\macro1.xlsm'!macro_name")  

why should i use the single quotes? does it not recognize the backslash?

Upvotes: 2

Views: 203

Answers (1)

GSerg
GSerg

Reputation: 78181

I believe it's for consistency.

Single quotes are necessary when the path contains spaces ot exclamation marks, so to make things more consistent and simple, the quotes are required every time.

Upvotes: 3

Related Questions