SET @bcpCommand = 'bcp "SELECT * FROM #Results" queryout "' + @FileName + '" -T -c -t,'
-- BEGIN TRY
EXEC xp_cmdshell @bcpCommand
as far as I'm aware bcp will open new connection which will not find your temp table #Results ...
How you are planing to execute your script? Is it going to be scheduled by some scheduling tool? It may have in-build functionality to dump the results to text file, so simple select * from #Results could do....