Power Automate: Automate your life pt.2

Hi everyone! This is the part 2 of our Power automate tutorial series. In this tutorial, we'll talk about the rest of the tutorial. 3) Time Tracking & Activity Logging Track how long you use certain apps (e.g., Word, VS Code) and log the usage to a file for productivity analysis. 4) Clipboard & Text Automation Monitor what you copy, log it to a file, or turn it into quick notes — perfect for saving research highlights or repetitive text snippets. 5) Automate Routine Daily Tasks Schedule PAD flows to run automatically at specific times (like launching your planner at 7 AM or logging reflections at 10 PM), so your day starts and ends with focus — without you doing anything manually. Let's start! Tutorial 3: Time Tracking & Activity Logging In this tutorial, we'll make a power automate flow that will track how long a specific app(e.g., VS Code) is running, and log the total usage time to a .txt file automatically when it closes. This is perfect for tracking study time, coding sessions, or focused work blocks. Now let's get started! STEP 1: Create a New Flow Open Power Automate Desktop Click New Flow Name it: Track VS Code Usage and click Create STEP 2: Get Start Time Search: Get current date and time Drag it to the top Save it as: StartTime STEP 3: Wait Until App (e.g., VS Code) Closes Search: "Wait for process to end" Drag it under StartTime Set: Process name: Code.exe (for VS Code — change for other apps) This step pauses the flow until VS Code is closed. STEP 4: Get End Time Search: Get current date and time Save it as: EndTime STEP 5: Calculate Time Difference Search: "Subtract dates" Set: From date: %EndTime% Subtract date: %StartTime% Get difference in: Minutes This gives you the time spent using the app. STEP 6: Format the log entry Use Set Variable Name: LogEntry Value: Used VS Code for %TimeDifference% minute(s) on %StartTime% Step 7: Append to a Log File Action: Append line to text file File path: e.g., C:\Users\YourName\Documents\usage_log.txt Text to append: %LogEntry% Well Done! Now every time you run this flow, It waits for you to open VS Code then times how long it's running then logs the result once you close the app! Tutorial 4: Clipboard & Text Automation In this tutorial, we will build an automation flow that will monitor what you copy (Ctrl+C), and log each copied text into a .txt file — perfect for saving useful links, research notes, or ideas on the go. Now let's get started! STEP 1: Create a New Flow Open Power Automate Desktop Click New Flow Name it: Clipboard Logger and click Create STEP 2: Initialize LastClipboardText (Before Loop) Action: Set Variable Name: LastClipboardText Value: "" (empty string) This ensures we have something to compare against — and it must be before the loop, not inside. STEP 3: Create a Loop That Keeps Running Search: Loop and choose: Loop condition Condition: First operand: 1 Operator: equals Second operand: 1 This creates an infinite loop to keep checking clipboard content. STEP 4: Get Current Clipboard Text Inside the loop, search for: Get clipboard text Drag it inside the loop Save output to: %ClipboardText% STEP 5: Compare With Previously Saved Text We don’t want to log duplicate clipboard values — so let’s compare with the last copied text. Inside Loop: Check if New Text ≠ Last Text Action: If First operand: %ClipboardText% Operator: Does not equal Second operand: %LastClipboardText% This ensures only new copied text gets logged. STEP 6: Log the Clipboard Text Inside the If block: Get Current Date & Time Action: Get current date and time Output variable: CurrentTime Format Log Entry Action: Set Variable Name: LogEntry Value: %CurrentTime% — %ClipboardText% Append to a File i. search for action: Write text to file ii. Drag it into your flow inside the If block (after Set LogEntry) iii. set value like this: File path: C:\Users\YourName\Documents\clipboard_log.txt Text to write: %LogEntry% Append content to existing file: ✔️ Check this box If file exists: Append content to existing file Encoding: Unicode or UTF-8 (both fine) Update LastClipboardText Action: Set Variable Variable: LastClipboardText Value: %ClipboardText% STEP 7: Add a Short Delay to Avoid Overload Action: Delay Duration: 2 seconds (or even 1) Done! Now this turns your clipboard into a smart, passive note-taker. Anytime you copy something — a quote, code snippet, research point, or idea — it’s automatically saved to a log file with a timestamp, without interrupting your workflow. Tutorial 5: Automate Routine Daily Tasks In our daily lives, we need to use many software on a frequent basis. For example, Google Calendar, Notes, Notion, Weather etc. In this tutorial, we'll build an automation flow that will automatically start your productivity apps at specific times without the need for manual setup. Let's get started! Step 1: Creat

Apr 15, 2025 - 04:20
 0
Power Automate: Automate your life pt.2

Hi everyone! This is the part 2 of our Power automate tutorial series. In this tutorial, we'll talk about the rest of the tutorial.

3) Time Tracking & Activity Logging
Track how long you use certain apps (e.g., Word, VS Code) and log the usage to a file for productivity analysis.

4) Clipboard & Text Automation
Monitor what you copy, log it to a file, or turn it into quick notes — perfect for saving research highlights or repetitive text snippets.

5) Automate Routine Daily Tasks
Schedule PAD flows to run automatically at specific times (like launching your planner at 7 AM or logging reflections at 10 PM), so your day starts and ends with focus — without you doing anything manually.

Let's start!

Tutorial 3: Time Tracking & Activity Logging

In this tutorial, we'll make a power automate flow that will track how long a specific app(e.g., VS Code) is running, and log the total usage time to a .txt file automatically when it closes. This is perfect for tracking study time, coding sessions, or focused work blocks. Now let's get started!

STEP 1: Create a New Flow

  1. Open Power Automate Desktop
  2. Click New Flow
  3. Name it: Track VS Code Usage and click Create

STEP 2: Get Start Time

  1. Search: Get current date and time
  2. Drag it to the top
  3. Save it as: StartTime

STEP 3: Wait Until App (e.g., VS Code) Closes

  1. Search: "Wait for process to end"
  2. Drag it under StartTime
  3. Set: Process name: Code.exe (for VS Code — change for other apps)

This step pauses the flow until VS Code is closed.

STEP 4: Get End Time

  1. Search: Get current date and time
  2. Save it as: EndTime

STEP 5: Calculate Time Difference

  1. Search: "Subtract dates"
  2. Set:

From date: %EndTime%

Subtract date: %StartTime%

Get difference in: Minutes

This gives you the time spent using the app.

STEP 6: Format the log entry

  1. Use Set Variable

Name: LogEntry

Value: Used VS Code for %TimeDifference% minute(s) on %StartTime%

Step 7: Append to a Log File

  1. Action: Append line to text file

File path: e.g., C:\Users\YourName\Documents\usage_log.txt

Text to append: %LogEntry%

Track Usage

Well Done! Now every time you run this flow, It waits for you to open VS Code then times how long it's running then logs the result once you close the app!

Tutorial 4: Clipboard & Text Automation

In this tutorial, we will build an automation flow that will monitor what you copy (Ctrl+C), and log each copied text into a .txt file — perfect for saving useful links, research notes, or ideas on the go.

Now let's get started!

STEP 1: Create a New Flow

  1. Open Power Automate Desktop
  2. Click New Flow
  3. Name it: Clipboard Logger and click Create

STEP 2: Initialize LastClipboardText (Before Loop)

  1. Action: Set Variable
  2. Name: LastClipboardText
  3. Value: "" (empty string)

This ensures we have something to compare against — and it must be before the loop, not inside.

STEP 3: Create a Loop That Keeps Running

  1. Search: Loop and choose: Loop condition
  2. Condition: First operand: 1 Operator: equals Second operand: 1

This creates an infinite loop to keep checking clipboard content.

STEP 4: Get Current Clipboard Text

  1. Inside the loop, search for: Get clipboard text
  2. Drag it inside the loop
  3. Save output to: %ClipboardText%

STEP 5: Compare With Previously Saved Text

We don’t want to log duplicate clipboard values — so let’s compare with the last copied text.

Inside Loop: Check if New Text ≠ Last Text
Action: If
First operand: %ClipboardText%
Operator: Does not equal
Second operand: %LastClipboardText%

This ensures only new copied text gets logged.

STEP 6: Log the Clipboard Text

Inside the If block:

  1. Get Current Date & Time

    Action: Get current date and time
    Output variable: CurrentTime

  2. Format Log Entry

    Action: Set Variable
    Name: LogEntry
    Value: %CurrentTime% — %ClipboardText%

  3. Append to a File

i. search for action: Write text to file
ii. Drag it into your flow inside the If block (after Set LogEntry)
iii. set value like this:

File path: C:\Users\YourName\Documents\clipboard_log.txt
Text to write: %LogEntry%
Append content to existing file: ✔️ Check this box
If file exists: Append content to existing file
Encoding: Unicode or UTF-8 (both fine)

  1. Update LastClipboardText

Action: Set Variable
Variable: LastClipboardText
Value: %ClipboardText%

STEP 7: Add a Short Delay to Avoid Overload

  1. Action: Delay
  2. Duration: 2 seconds (or even 1)

Clipboard logger

Done! Now this turns your clipboard into a smart, passive note-taker. Anytime you copy something — a quote, code snippet, research point, or idea — it’s automatically saved to a log file with a timestamp, without interrupting your workflow.

Tutorial 5: Automate Routine Daily Tasks

In our daily lives, we need to use many software on a frequent basis. For example, Google Calendar, Notes, Notion, Weather etc. In this tutorial, we'll build an automation flow that will automatically start your productivity apps at specific times without the need for manual setup.

Let's get started!

Step 1: Create the Flow in PAD

  1. Open Power Automate Desktop
  2. Click New Flow
  3. Name it "Launch Daily Planner" and click create.

Step 2: Open Google Calendar

  1. Search: Launch new Chrome
  2. Drag into your flow
  3. Set: URL: https://calendar.google.com Window state: Normal Target Desktop: Local Computer

**Step 3: Open Weather Forecast

  1. Search: Launch new Chrome
  2. Drag it below the first Chrome action
  3. Set: URL: https://weather.com/weather/today/l/your-location-code (You can use your city or Google Weather like https://www.google.com/search?q=weather+tokyo) Window state: Normal Target Desktop: Local Computer

Step 4: Open Notepad

  1. Search: Run application
  2. Drag into the flow
  3. Set: Application path: C:\Windows\System32\notepad.exe

Step 6: Save Your Flow

  1. Click the Save icon (