Forum Discussion

AB21805's avatar
AB21805
Bronze Contributor
Mar 01, 2022
Solved

How to open up wordpad on start up via intune

Hi all,

 

How do I set it so when users log in word pad opens or set it so on specific accounts word pad opens

 

Thanks in advance

 

  • It runs as system… just change the url to wordpad indeed … let me know if it works for you

5 Replies

  • I guess something like this...

    #Create shortcut in all users startup folder
    if (-not (Test-Path "C:\Users\Public\Desktop\RemoteApp.url"))
    {
    $null = $WshShell = New-Object -comObject WScript.Shell
    $path = "C:\ProgramData\Microsoft\Windows\Start Menu\Programs\Startup\winword.url"
    $targetpath = "C:\Program Files\Microsoft Office\root\Office16\winword.exe"
    $iconlocation = "C:\Program Files\Microsoft Office\root\Office16\winword.exe"
    $iconfile = "IconFile=" + $iconlocation
    $Shortcut = $WshShell.CreateShortcut($path)
    $Shortcut.TargetPath = $targetpath
    $Shortcut.Save()

    Add-Content $path "HotKey=0"
    Add-Content $path "$iconfile"
    Add-Content $path "IconIndex=0"
    }

    • AB21805's avatar
      AB21805
      Bronze Contributor
      ill give this a go! Would this be set to devices or users? Also by logged in credentials or System?

      If I wanted to open wordpad instead of word I would just need to change the targetpath and icon location?
      • It runs as system… just change the url to wordpad indeed … let me know if it works for you

Resources