SetAccountInformation(AccountName, Password)

Set username and password under which task will run


AccountName : unicode

AccountName, use "" for local system account (can only be used by Administrators)

Password : unicode

Password - Can be None for local System account, or if TASK_FLAG_RUN_ONLY_IF_LOGGED_ON is set


On some systems, username and password are verified at the time the task is saved, on others when the task tries to run