how to get rid of the response from Exchange when password is invalid and catch error message instead?
I have the following command: $null = Connect-ExchangeOnline -Credential $cred -PSSessionOption $proxyOptions -ShowBanner:$false -ErrorAction Stop SilentlyContinue -WarningAction SilentlyContinue -InformationAction SilentlyContinue -ErrorVariable…
Update Micorosoft Store and Store Apps with command line?
Hi To update Microsoft Store and Store Apps, I navigate to the Store and select "Get Updates", like above screenshot. Question: Is there any possibility to achieve the same with Command Line /Power Shell or DISM?
Powershell script to enable Microsoft.SQL service endpoint and add to Azure SQL
We have certain VM's that need to be able to access Azure SQL. Since allow public access is turned off, I need to add the Virtual Network/Subnet to SQL Instance. Then also, I need to enable Microsoft.SQL for the service endpoint on any of the subnets…
Warning PowerShell ID 300
Hi, More than a year after reporting the problem, I continue to receive the same PowerShell warning despite everything working normally and all versions being up to date. Maybe with this new information we can better understand the problem. I know it…
How to find and remove security group from local admin group with Powershell
How would I write this in PS where I'm looking for or checking for "Company\Domain Admins" security group from local Administrators group? Get-LocalGroupMember -Group "Administrators" (Gives me a list of groups that are in the Local…
unable to connect Azure
Hi All I use the below syntax to connect to Azure Powershell, but today i am unable to connect to azure powershell. it prompts me to enter tenant and subscription number. I have 1500 subscriptions, how can i know the subscription number for my…
How to capture Error like Get-AzRoleAssignment : Operation returned an invalid status code 'NotFound' and do some activity in if-else block based on this error
How to capture Error like Get-AzRoleAssignment : Operation returned an invalid status code 'NotFound' and do some activity in if-else block based on this error
How to use splatting
I am looking for some help with splatting , I have the below lines to grab a registry key and want it to be passed into a hash table to make it more simpler to view to reduce the length if ($Version -ge 16) { # Grab the value of SAID…
Identification of Process for termination
When I am opening a Power BI file, sometimes the below window pops up : How can I identify this process and terminate it in an automated way? Note : I tried to get distinct process name prior to opening this file and post that and there were several…
Exporting Power Platform environment as CSV or Spreadsheet file?
How can I export the list of Power Platform environments shown in this page: https://admin.powerplatform.microsoft.com/environments as .CSV file ? I need to perform an audit of thousands of unused environments in my tenant.
Access Blob storage using SAS Key via PowerShell
Hi I want to be able to access Blob storage using a SAS key in PowerShell. I have the SAS key set up on the storage account, limited to the IP of the server I'm running the PowerShell from. I want to be able to use the key without signing into Azure or…
Windows 2022 Server TLS 1.2 is enabled - PowerShell Error
Windows 2022 Server TLS 1.2 is enabled - PowerShell Error WARNING: MSG:UnableToDownload «https://go.microsoft.com/fwlink/?LinkID=627338&clcid=0x409» «» For PowerShell to work I can run [Net.ServicePointManager]::SecurityProtocol =…
How can I check if my OnPremise Exchange Server is still sending email as relay to the outside world?
How can I verify and check if my Exchange Servers are still sending emails to the external world? Because from this page I cannot see any list of servers: https://admin.exchange.microsoft.com/#/reports/onpremunpatchedserverdetails
WinGet.exe upgrade --all -Exclude
How to exclude the list of apps [third-party application, MS applications, and MS KBnumbers] while running winget upgrade -all commands. Is there any parameter to exclude any application? It will be appriciated
Azure File share mounted drive showing Disconnected Network Drive
I am using Microsoft Azure Fluent API with RunPowerShellScript method to execute powershell script. My file share drive mounted properly but it's showing disconnected .When i click on disconnected drive it's showing files properly. But same powershell…
copy files using robocopy
Hi All My VM is hosted in Azure. I want to copy a folder (which contains subfolders and files, and some of the subfolder and file names exceed the 255-character limit) from one local drive to another. My local drive is the E drive, and the destination…
PowerShell - Get-Localuser PasswordExpires
Hi Guys How do I check if the local user has "password expires" true or false? Thank you very much in advance
KMS migration from 2012 OS to 2019 OS
Hi There, We have our working KMS services currently running in Windows 2012 R2 server and we are looking to plan for migration to 2019 OS. Server is hosted in our vcenter host and need a plan to execute this. Kindly assist us with the steps to go…
Credential Manager, PnP Powershell and SQL Agent Proxy permissions
Hi, I have SQL Agent Job that runs cmdexec via Proxy user and executes pnp ps1 script that picks credentials from Credential Manager and connects to Sharepoint online. This is the commands that connects to Sharepoint: Connect-PnPOnline -Url…
Azure Cloud Shell is stuck on Connecting terminal...
So i have an issue where i try to connect to azure cloud shell and it says Requesting a Cloud Shell.Succeeded. Connecting terminal... and it just stuck there for more than 40 minutes now. Is there anything i can do? I try different browsers, chrome,…