For what you are doing, you would need to use an intermediate step in order to Extract the Data from your Dynamic Variable. 
set %Var1 10 
set %Var2 String 
set %Temp %Var1 , %Var2 
set % , %Temp Worked
display % . %Temp
Halt
The Easiest way to get around this is just to Bypass the Var2. 
set %Var1 10
set %String , %Var1 Worked
Display %String . %Var1
halt
Once you get the Hang of it, its not Tooo Bad.