Forum Discussion

3 Replies

  • Reza_Ameri's avatar
    Reza_Ameri
    Silver Contributor
    You just want to prevent login?
    One approach is to use Task Schedule and create a task to start two PowerShell commands, one to disable the user and the other one to enable the user.
    Will that address your issue?
    • AB21805's avatar
      AB21805
      Bronze Contributor
      What would this look like? The devices are cloud only intune managed devices
      • Reza_Ameri's avatar
        Reza_Ameri
        Silver Contributor
        You may run PowerShell in the Intune, have a look at:
        https://learn.microsoft.com/en-us/mem/intune/apps/intune-management-extension
        Then you may run command to Schedule task, have a look at:
        https://learn.microsoft.com/en-us/powershell/module/scheduledtasks/new-scheduledtaskaction

Resources