You need to run all the commands together. It didn't work for me when I tried to run them separately.
1: ALTER DATABASE MyAppDB SET SINGLE_USER WITH ROLLBACK IMMEDIATE
2: RESTORE DATABASE MyAppDB FROM DISK = 'E:\DBBackups\MyApp_db_201008032143.BAK' WITH REPLACE
3: ALTER DATABASE MyAppDB SET MULTI_USER