You can use variables. I am curious though, are you using a variable for the image name? If I do that I get the same error you are seeing. My question would be, how are you using variables that it is beneficial to leverage a varialbe for the image name?
\\%coreserver%\%myfolder%\test.tbi works fine where %myfolder% is a template variable.