Verify the Logid status
-
@scottalanmiller 1500 Numbers of Different Usernames
-
@lakshmana said in Verify the Logid status:
@scottalanmiller 1500 Numbers of Different Usernames
Okay, then write it like this.... 1,500 usernames. The comma, the capital letter, the lack of plural ending all indicate something other than you were intending.
Now that we have an idea of what we are trying, which 1,500 as it is not all that are in the file? How do we determine which 1,500?
-
The .csv file have Serial Number staring from 1-1500 numbers where the usernames are mentioned where i need to check whether it is disabled or not from AD
-
@scottalanmiller said in Verify the Logid status:
@lakshmana said in Verify the Logid status:
@scottalanmiller 1500 Numbers of Different Usernames
Okay, then write it like this.... 1,500 usernames. The comma, the capital letter, the lack of plural ending all indicate something other than you were intending.
Now that we have an idea of what we are trying, which 1,500 as it is not all that are in the file? How do we determine which 1,500?
Whether the above powershell can be used for my commands ?
-
Maybe make two files, then just loop through them. Without having the files and their exact formats, there is no way for us to help beyond giving high level ideas.
-
@scottalanmiller How to do that ?
-
Need to have .csv in two different location ?
-
the command to get the output in powershell is (Get-ADUser Username).Enabled.
Need to use this in powershell
-
@lakshmana said in Verify the Logid status:
Need to have .csv in two different location ?
Two files but one location.
-
@lakshmana said in Verify the Logid status:
the command to get the output in powershell is (Get-ADUser Username).Enabled.
Need to use this in powershell
In BASH this would be so easy. Or Python.
-
@scottalanmiller Through the powershell i am running this
$UsersFromFile = Get-Content -Path 'd:\temp\UserList.csv'
ForEach ($Username in $UsersFromFile)
{(Get-ADUser -Identity $UserName).Enabled}Where the data is fetching but error comes there for all the users.I need to append the status in the .csv too
-
@lakshmana The above helps me and its working but i need the output of that file to be append at the same .csv file which is not working.How to do that ?