help: win2016 "Start a program on connection" problems with %appdata%

Posted by zandadoum@reddit | sysadmin | View on Reddit | 6 comments

Hello, I hope I explain well. english is not main language and that's also what makes my internet searches more difficult. I am at my wits end here with a legacy software that we want to use through RDP on some older Datalogic Skorpio (x3 and x4) The problem is when creating new users: the user is added to several groups, most importantly group that autoexec c:\\myapp\\launcher.exe (through the GPO "Start a program on connection") our launcher then allows to start other apps they need, one of them doesn't work right away tho it's an old 3rd party (obsolete, but will require a couple years to phase out) that requires some cache temporary folders in c:\\users\\user\\appdata this folder doesn't exist when creating a new user and with the GPO "Start a program on connection" apparently is not created properly THE WORKAROUND: the workaround is to remove the user from the "autoexec" for aa few minutes, log in manually to that user so windows creates those folders upon first login, then add the user back to the "autoexec" GPO and now everything works ​ so, when logging in manual once, %appdata% cache folders are created properly (with proper persmissions) but when the GPO "Start a program on connection" is enabled from the very beginning, it doesn't work we don't have remote folders or any of that. is there a way to solve this so we don't have to log into the user manually without autoexec every time we make a new user?