Windows 10: PowerShell Script to find out Inactive users for 90 days and disable and move them to the...

Discus and support PowerShell Script to find out Inactive users for 90 days and disable and move them to the... in Windows 10 Gaming to solve the problem; Hi Guys, I want to automate the following process with a PowerShell script in the Domain Controller, Windows Server 2019.1. Find out all the users who... Discussion in 'Windows 10 Gaming' started by Oliver Dalugodage, Feb 27, 2023.

  1. PowerShell Script to find out Inactive users for 90 days and disable and move them to the...


    Hi Guys, I want to automate the following process with a PowerShell script in the Domain Controller, Windows Server 2019.1. Find out all the users who have not logged in using the AD account in the last 90 days, disable them, and move them to the disable OU.I ran the following Powershell script and found out it is not accurate. It even found my account as inactive.$inactivity = New-TimeSpan -Days 90Search-ADAccount -UsersOnly -AccountInactive -TimeSpan $inactivity Please help. Thank you so much for your attention and participation.

    :)
     
    Oliver Dalugodage, Feb 27, 2023
    #1

  2. USB removable storage disable by powershell script

    Hello All,

    I want to disable the usb removable storage of the network computers (domain and non-domain) from my computer. But i need powershell script which will disable the usb removable storage of mentioned computer list but through the local group policy not thorough
    regedit of that computer also not through the GPO which is in server OS.

    Please help me. Thank You.
     
    JagdishPatil_4994, Feb 27, 2023
    #2
  3. PowerShell scripts not working with Call operator

    Hi,



    Thank you for writing to Microsoft Community Forums.



    I understand that you are facing issues while developing a PowerShell script using the Call operator. I would suggest you to refer the articles

    The Windows PowerShell ISE
    .



    However, as the issue is related to developing PowerShell scripts, I would suggest you to post your query on

    MSDN forums
    , where we have expertise and developers who are well equipped with the knowledge of developing PowerShell scripts in Windows.



    Regards,

    Prakhar Khare

    Microsoft Community – Moderator
     
    Prakhar_Khare, Feb 27, 2023
    #3
  4. Studynxx Win User

    PowerShell Script to find out Inactive users for 90 days and disable and move them to the...

    Powershell / Batch scripts do NOT run!

    Please help me. I have written some powershell and batch scripts, yet when I run those files, they don't run. At most the powershell script just does step #1 but not all the other steps (lines of code / instructions). The batch script .bat file doesn't do anything. Both just pop up for like 2 seconds and then they disappear, Task Manager says nothing's being done.
     
    Studynxx, Feb 27, 2023
    #4
Thema:

PowerShell Script to find out Inactive users for 90 days and disable and move them to the...

Loading...
  1. PowerShell Script to find out Inactive users for 90 days and disable and move them to the... - Similar Threads - PowerShell Script find

  2. PowerShell Script to find out Inactive users for 90 days and disable and move them to the...

    in Windows 10 Software and Apps
    PowerShell Script to find out Inactive users for 90 days and disable and move them to the...: Hi Guys, I want to automate the following process with a PowerShell script in the Domain Controller, Windows Server 2019.1. Find out all the users who have not logged in using the AD account in the last 90 days, disable them, and move them to the disable OU.I ran the...
  3. PowerShell script to disable/enable usb storage in windows

    in Windows 10 Gaming
    PowerShell script to disable/enable usb storage in windows: Hello,can someone please help me with a PowerShell script, which will disable usb storage.requirements:1 everything should be done through PowerShell script2 already installed usb should not be accessible 3 not ready to install any 3rd party application4 Restarting pc is not...
  4. PowerShell script to disable/enable usb storage in windows

    in Windows 10 Drivers and Hardware
    PowerShell script to disable/enable usb storage in windows: Hello,can someone please help me with a PowerShell script, which will disable usb storage.requirements:1 everything should be done through PowerShell script2 already installed usb should not be accessible 3 not ready to install any 3rd party application4 Restarting pc is not...
  5. PowerShell script

    in Windows 10 Support
    PowerShell script: The code below tests a series of IPs in a txt file.The result is as follows and is written in a txt file. 19.191.12.161 - online 19.191.12.162 - offline 19.191.12.163 - offline 19.191.12.164 - offline 19.191.12.165 - offline also see the scrennshot Code: $Output= @()$GetIP =...
  6. USB removable storage disable by powershell script

    in Windows 10 Drivers and Hardware
    USB removable storage disable by powershell script: Hello All, I want to disable the usb removable storage of the network computers domain and non-domain from my computer. But i need powershell script which will disable the usb removable storage of mentioned computer list but through the local group policy not thorough...
  7. powershell scripts

    in AntiVirus, Firewalls and System Security
    powershell scripts: Hi, I have azure. Someone is somehow installing powershell scripts onto my computer that allows them to host my PC through P2P and UDP connections, well I think so anyway. I have only just found powershell script entry changes in my registry by accident. These criminals...
  8. powershell script

    in Windows 10 Customization
    powershell script: looking for a script to monitor for a folder, if there is a file in that folder send it as an email, once the email is sent out, confirm and then move the files to an archive folder. monitor c:\test\*.pdf No files, do not send email. Yes Files, send an email to someone at...
  9. Question about where to find info for Powershell script

    in Windows 10 Ask Insider
    Question about where to find info for Powershell script: I looked up how to remove Candy crush and the following command did work: Remove-AppxPackage king.com.CandyCrushFriends1.26.7.0_x86_kgqvnymyfvs32 My question is where do you find the "king.com" part so i also get rid of other things without an exact guide such as Farm...
  10. CMD script to run other scripts then end them after a day

    in Windows 10 BSOD Crashes and Debugging
    CMD script to run other scripts then end them after a day: I need to write a cmd script that I can run and it will start another bash script. Then. After 24 Hours stop that process and restart it https://answers.microsoft.com/en-us/windows/forum/all/cmd-script-to-run-other-scripts-then-end-them/db8702d0-b02b-4447-a80d-2b6a660ef7a5