No you cannot pass variables into SS template tags (must be defined a constant). EG $Foo(Bar) will work but $Foo($Bar) won't. This is because the template parser only runs over the code once. So it will look for a function Foo and will pass a function Bar too it which is annoying but its one of the limitations of SSViewer. You'll have to find another way to do what you want.