Category "powershell"

Are all CMD commands available within powershell?

Similar to other questions, but are ALL CMD commands usable within Powershell? In short, can I use a Powershell window to supplant CMD prompts, and do both CMD

How to programmatically change tier of Azure SQL Database

We have a large SQL Database running on Azure which is only generally in use during normal office hours, although from time to time, overtime/weekend staff will

How to programmatically change tier of Azure SQL Database

We have a large SQL Database running on Azure which is only generally in use during normal office hours, although from time to time, overtime/weekend staff will

Export Powershell to txt file

I have a powershell script that I run and would like it to export to a txt file when completed. But it should not overwrite the existing output file Any sugge

Log errors after running robocopy command

I am running a robocopy command to copy files from one folder to another like below - "Robocopy source destination filename" Some files are not getting copied a

Adding Shared Printer to Remote Computer via Powershell

I am unable to run an invoke-command script to install printers on a remote machine. My code works locally, but as soon as I pipe it into Invoke-command, i get

Powershell Copy Files with a Blacklist (Exclude) and a Whitelist (Include)

I'm translating some msbuild scripts to powershell. In msbuild, I can generate a blacklist and/or whitelist of files I want to (recursively) copy to a destinat

Creating a powershell function that will take on ONE parameter and outputs a concatenated string value (fname+lname)

I'm looking for some guidance or tips for how to revise the function below. My goal is create a function that accepts one parameter and then returns a string. I

docker: error during connect: In the default daemon configuration on Windows, the docker client must be run with elevated privileges to connect

I'm trying to run Docker in process isolation mode on Windows Server 2019 (Docker Desktop does not work here, my VPS does not support Hyper-V). I run this in Po

Where can I find an official source for one-liner command line tools available through pip install?

More specifically, I have been using speedtest-cli in Windows PowerShell. I was able to get this tool by using "pip install speedtest-cli". This tool tests my u

Get-AzureADAuditSignInLogs returning $null in Automation Accounts

I have a simple script to get the last sign in details for each user in Azure. When running the script from Visual Studio, it all runs fine with no errors. Afte

keyboard events are logged by the python script and powershell which runs the python script at the same time

I am running into an issue where I am trying to read/write to serial port from windows, its similar to teraterm/putty but trying to customize it for personal us

How to add signature to powershell code creating new mail?

I want signatures to show up when creating new message as they do with Ctrl+N? Here is my code: $Outlook = New-Object -ComObject Outlook.Application $Mail = $O

Resume Azure VM backup using powershell script after disabling backup

I would like to resume my backup after disabling backup. Used the below commands for disabling and enabling. Disabling backup :Disable-AzRecoveryServicesBackupP

Strange Powershell "interactive" behavior

Sometimes, when using certain commands within Powershell, the console is set into some kind of "interactive mode", which makes it behave in a way that's complet

powershell signing certificate unknownerror

I am following the instructions to sign a script and I've got to the part where I sign the add-signature.ps1 file so that I can sign my script using it $cert =

powershell signing certificate unknownerror

I am following the instructions to sign a script and I've got to the part where I sign the add-signature.ps1 file so that I can sign my script using it $cert =

Is there any way to export the contents of my Teams Chats for one day, by chat and time?

Is there any way to get and list out all my conversations in teams chats for one day? When I'm logging time, I lose track of what I worked on when I'm helping o

Howto use psexec via powershell invoke-command on a remote computer? (invalid handle)

I have written a powershell script which creates a powershell script or a batch script depending on the remote host on which this script should be started remot

How to clear the entire terminal (PowerShell)

I had an issue. Using the clear or cls command in powershell clears only the visible portion of the terminal,I would like to know how to clear the entire termin