Search found 216 matches
- Tue Sep 15, 2020 4:40 pm
- Forum: PowerShell
- Topic: Resolve Unique IP and Send Email?
- Replies: 5
- Views: 4138
Re: Resolve Unique IP and Send Email?
To send an object collection as HTML you would use "ConvertTo-Html" . $body = $results | ConvertTo-Html | Out-String Hi Mr. Vierra, Yes, that works partially on the email body to show the $Results content. However, how to allow the output to be like: Unique IP address: 192.168.1.66 - LAPT...
- Tue Sep 15, 2020 6:03 am
- Forum: PowerShell
- Topic: How to gather unique directory name and then export as CSV or Out-GridView?
- Replies: 3
- Views: 3362
How to gather unique directory name and then export as CSV or Out-GridView?
Hi Everyone, The below script is working fine to list all explicitly defined ACL in my file server directories with the below specific exclusion pattern. 'NT AUTHORITY\SYSTEM', 'BUILTIN\Administrators', 'CREATOR OWNER', 'Everyone', 'DOMAIN\SERVICE-AVScan, 'S-1-5-21' However, I need some help in the ...
- Tue Sep 15, 2020 6:01 am
- Forum: PowerShell
- Topic: Resolve Unique IP and Send Email?
- Replies: 5
- Views: 4138
Resolve Unique IP and Send Email?
Hi All, The below contents are from the $Results variable I got from my larger script. MachineName : PRDDC03.domain.com Id : 4624 TimeCreated : 4/09/2020 12:12:12 PM Account : DOMAIN\SVC-SQL LogonType : 3 LogonTypeString : Network WorkstationName : SourceIP : 172.16.32.99 SourceName : MachineName : ...
- Wed Aug 19, 2020 8:18 pm
- Forum: PowerShell
- Topic: Filtering Enabled only Get-ADObject to with specific patterns and OU?
- Replies: 12
- Views: 9321
Re: Filtering Enabled only Get-ADObject to with specific patterns and OU?
I think the issue is that the Get-AdUser and Get-AdComputer commands add the "Enabled" property by converting the flags but Get-AdObject does not do this. You will have to extract the attribute and test the bit after extracting the objects. Yes, that's too complex for me to do :-o hence I...
- Wed Aug 19, 2020 7:53 pm
- Forum: PowerShell
- Topic: Filtering Enabled only Get-ADObject to with specific patterns and OU?
- Replies: 12
- Views: 9321
- Wed Aug 19, 2020 7:02 pm
- Forum: PowerShell
- Topic: Filtering Enabled only Get-ADObject to with specific patterns and OU?
- Replies: 12
- Views: 9321
Re: Filtering Enabled only Get-ADObject to with specific patterns and OU?
Yes, already did. $filter = ' ( ObjectClass -eq "user" -or ObjectClass -eq "computer" ) -and Enabled -eq $true ' Get-ADObject -Filter $filter The script above returns all Users and Computers object. but when I add Enabled -eq $true , it does not returns anything at all?
- Wed Aug 19, 2020 6:44 pm
- Forum: PowerShell
- Topic: Filtering Enabled only Get-ADObject to with specific patterns and OU?
- Replies: 12
- Views: 9321
Re: Filtering Enabled only Get-ADObject to with specific patterns and OU?
Thank you Mr. Vierra,
Somehow it does not return any result?
even after removing the Enabled -eq $true
I've also changed it into Where-Object{$_.Name -notcontains $Exclusions}
Somehow it does not return any result?
even after removing the Enabled -eq $true
I've also changed it into Where-Object{$_.Name -notcontains $Exclusions}
- Wed Aug 19, 2020 6:07 pm
- Forum: PowerShell
- Topic: Filtering Enabled only Get-ADObject to with specific patterns and OU?
- Replies: 12
- Views: 9321
Filtering Enabled only Get-ADObject to with specific patterns and OU?
Hi All, I need to get the Enabled AD Objects (Users & Computer) that does not include the specific name patterns. How can I filter out or exclude some of the results using the Get-ADObject with the below Query? Script: $Exclusions = @( 'SystemMailbox', 'HealthMailbox', 'Migration' 'Delete' 'Disa...
- Tue Jul 28, 2020 2:46 am
- Forum: PowerShell
- Topic: Calling hash Table inside Calculated property issue?
- Replies: 0
- Views: 12655
Calling hash Table inside Calculated property issue?
Hi Folks, I need some help to fix the one line which maps the values of a number to a string in this Hashtable. $mailboxType = @{ "0" = "UserMailbox" "1073741824" = "Shared Mailbox" "6" = "MailUser" "7" = "Room" "8&...
- Sat Jul 18, 2020 1:26 am
- Forum: PowerShell
- Topic: Updating specific registry entry using Powershell and Try/Catch?
- Replies: 6
- Views: 2706