I did some more experiementing and found that
strSQL = "execute block (name varchar(50) = ?) returns (NAME_ID INT) as " & _
"Begin " & _
" INSERT INTO TABLE1(NAME) VALUES(:name) RETURNING ID INTO :NAME_ID; " & _
"End"
works as well. This is more advantageous since there is much less anonymous block PSQL code to write