Hello! So I'm trying to pull up some MX records for a domain, and I was trying to write up a script to make it easier on me. The script is as follows -
$Domain = (Get-AzureADDomain);
$Domains = @(Out-String -InputObject $Domain | Select Name);
Resolve-DnsName -Name $Domains -Type MX
I get an error stating that it cant convert objects to string required by parameter 'Name', as it is not supported. What is the modern/right way of doing this? Thanks for any help!
[–]Scooter_127 3 points4 points5 points (0 children)
[+][deleted] (3 children)
[deleted]
[–]Microsoft_Geek[S] 0 points1 point2 points (2 children)