Skip to main content
100%

Gist ea8710410afc9bb88a65f846e46d04da

✓ Published0🌍 Public
HHerbCaudill
Last edited Jun 22, 2019
Created on Jun 22, 2019

This example demonstrates how to automate opening a Google Sheets tab in Chrome at user logon and session unlock, using a PowerShell script to register a Windows scheduled task. The task triggers on logon and session unlock events, launching Chrome with an app-mode URL pointing directly to the spreadsheet. The code constructs an XML task definition with the `Register-ScheduledTask` cmdlet, embedding the Chrome executable path and the spreadsheet URL as arguments. It highlights the use of PowerShell’s scheduled task API and XML trigger configuration, showing a practical workflow automation for persistent access to a specific data source without manual intervention.

AI-generated description

Similar vizzes