What you want is to follow VBS shell code, use Win32::GuiTest or Win32::OLE
In reply to Re^2: Windows runas command by Anonymous Monk in thread Windows runas command by flintstone