WinBatch® Technical Support Forum

All Things WinBatch => WinBatch => Topic started by: krasdude on November 21, 2019, 02:56:09 PM

Title: Ability to start WinBatch script as one user, then change during execution
Post by: krasdude on November 21, 2019, 02:56:09 PM
Hello all

Is there way within WinBatch.  I have several scripts that accesses \\machine\C$ and do some things we need.  Is there a way to start the script as normal user account so it can read host file, start Excel and such from OneDrive, then right when it's time to access the code to access C$, switch to another AD account that has permissions to access C$?

I tried RUNAS (Shift-right click) but keep getting Windows Access error.  I'd prefer not logging into laptop as other AD account as that has other issues.  Just curious if anyone has any thoughts

Thanks all
Title: Re: Ability to start WinBatch script as one user, then change during execution
Post by: krasdude on November 21, 2019, 03:13:27 PM
Sorry to bother, I found my answer.  thanks.