Hi Ravi
generally speaking the program flow in background sometimes is different than foreground, that's why in first instance I always analyze auths
Transaction ST01 and select a user that you will use only for the background activity (bear in mind to activate this only after last dialog)
Let me know how it goes
a