+ Post New Thread
Results 1 to 10 of 10
Windows 8 Thread, PowerShell logon script for a off the network windows 8.1 machine in Technical; Hi all, long time since I've been on here. I've wrote a PowerShell script I want to run which is ...
  1. #1
    andy_nic's Avatar
    Join Date
    Jun 2008
    Location
    Peterborough
    Posts
    445
    Thank Post
    31
    Thanked 39 Times in 33 Posts
    Rep Power
    19

    PowerShell logon script for a off the network windows 8.1 machine

    Hi all,
    long time since I've been on here.
    I've wrote a PowerShell script I want to run which is a dialog box which if yes is clicked, then deletes files off a local users desktop. I've set up local GPO to the following

    Under User Configuration\Windows Settings\Script(Logon/Logoff) logon script to the PowerShell script.
    Under User Configuration\Administrative Templates\System\Scripts I've set "Display instructions as they run" to enable which allows the script to display what is running to allow the dialog box.

    I've restarted the computer with network cable as in the past local GPO won't apply until the network GPO has applied. As this computer is also added to domain.

    but it still won't display, not even sure its running the script.

    is this even possible?

    Andrew

  2. #2


    Join Date
    Mar 2009
    Location
    Leeds
    Posts
    6,591
    Thank Post
    228
    Thanked 856 Times in 735 Posts
    Rep Power
    296
    whats your powershell executuion policy set to as by default it wont run scripts get-execution policy should tell you and it can be changed via group policy (both user and computer) admin templates windows components\windows powershell (theres only one setting there with various options)

  3. #3
    andy_nic's Avatar
    Join Date
    Jun 2008
    Location
    Peterborough
    Posts
    445
    Thank Post
    31
    Thanked 39 Times in 33 Posts
    Rep Power
    19
    I normally set it to remotesigned.

  4. #4
    andy_nic's Avatar
    Join Date
    Jun 2008
    Location
    Peterborough
    Posts
    445
    Thank Post
    31
    Thanked 39 Times in 33 Posts
    Rep Power
    19
    It appears to be working, but takes 5mins for it to load.

  5. #5


    Join Date
    Feb 2007
    Location
    51.403651, -0.515458
    Posts
    8,900
    Thank Post
    226
    Thanked 2,676 Times in 1,973 Posts
    Rep Power
    787
    Quote Originally Posted by sted View Post
    by default it won't run scripts
    Logon scripts will run regardless of the local script execution policy.

  6. Thanks to Arthur from:

    sted (19th June 2014)

  7. #6


    Join Date
    Feb 2007
    Location
    51.403651, -0.515458
    Posts
    8,900
    Thank Post
    226
    Thanked 2,676 Times in 1,973 Posts
    Rep Power
    787
    Quote Originally Posted by andy_nic View Post
    It appears to be working, but takes 5 mins for it to load.
    You probably already know this, but the delay can be changed via Group Policy.

    Windows 8.1 Logon Script Delay Group Policy Setting

  8. #7


    Join Date
    Mar 2009
    Location
    Leeds
    Posts
    6,591
    Thank Post
    228
    Thanked 856 Times in 735 Posts
    Rep Power
    296
    Quote Originally Posted by Arthur View Post
    good to know i assume the same is true for startup/shutdown/logoff?

  9. #8


    Join Date
    Feb 2007
    Location
    51.403651, -0.515458
    Posts
    8,900
    Thank Post
    226
    Thanked 2,676 Times in 1,973 Posts
    Rep Power
    787
    Quote Originally Posted by sted View Post
    good to know I assume the same is true for startup/shutdown/logoff?
    I would assume so since it wouldn't make any sense to do one thing for logon scripts and something else for the other scripts.

  10. #9


    Join Date
    Mar 2009
    Location
    Leeds
    Posts
    6,591
    Thank Post
    228
    Thanked 856 Times in 735 Posts
    Rep Power
    296
    Quote Originally Posted by Arthur View Post
    I would assume so since it wouldn't make any sense to do one thing for logon scripts and something else for the other scripts.
    sense dosent always apply to microsoft though lol

  11. #10


    Join Date
    Feb 2007
    Location
    51.403651, -0.515458
    Posts
    8,900
    Thank Post
    226
    Thanked 2,676 Times in 1,973 Posts
    Rep Power
    787
    Quote Originally Posted by sted View Post
    sense doesn't always apply to Microsoft though lol
    Very true!

SHARE:
+ Post New Thread

Similar Threads

  1. Terminal server logon script for printers
    By cookie_monster in forum Scripts
    Replies: 11
    Last Post: 13th August 2008, 11:46 AM
  2. logon script for printer
    By ozzy in forum Scripts
    Replies: 6
    Last Post: 22nd November 2007, 03:03 PM
  3. Replies: 2
    Last Post: 7th December 2006, 10:08 AM
  4. Getting the GUIDs for pcs on the network
    By HodgeHi in forum Wireless Networks
    Replies: 13
    Last Post: 4th December 2006, 09:33 PM
  5. PCs dropping off the network
    By SpuffMonkey in forum Windows
    Replies: 11
    Last Post: 2nd March 2006, 10:10 AM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •