Quantcast
Channel: Windows PowerShell forum
Browsing all 21975 articles
Browse latest View live

how to rename domain computers with powershell script

Hi all, Our company using domain environment, and the computers had been joined to the domain,  now we need to rename the computers with new requirements. How can i achieve it with powershell scripts...

View Article


Need help with query inbox rules

Hi All, I am trying to search and find all inbox rules in exchange and the script is working good if I don't have users with multiple mailboxes. If I have user test.test  and if he has 4 mailboxes the...

View Article


start-process -verb Printto

Objective: Print adobe files from powershell to a specific network printer (not default printer).$portname=\\printname\quename Start-Process $Adobe -filepath $pdf -ArgumentList $arglist -Verb...

View Article

Creating -body parameters for Invoke-RestMethod / Invoke-PowerBIRestMethod

We have a lot of data sources listed on our Power BI gateway (~200) and an IS enforced policy to change passwords every 45 days. The current process is for someone to go through these data sources and...

View Article

Extract group Policies of multiple Servers through PowerShell

HelloI wrote a script which is supposed to gather group policies on more than 300 servers. The CSV file has just one Column and it is called IP.# DO NOT FORGET To start Windows PowerShell with elevated...

View Article


Listing all the patches/updates installed in Windows machine

Hi AllI want a script to list all the patches/updates installed in my PC. I tried the below script but it does not give me complete list of patches [SQL, Visual Studio, some Office patches are not...

View Article

Convert to GB

Want to convert to GB from the script belowGet-VM | ForEach-Object {  $VM = $_  $_.Guest.Disks | ForEach-Object {    $Report = "" | Select-Object -Property VM,Path,Capacity,FreeSpace    $Report.VM =...

View Article

Powershell script not running when using TaskScheduler

Hello,I cannot get a simple powerhsell script to execute using the task scheduler.I have the following parameters:powershell.exe  -ExecutionPolicy ByPass -WindowStyle Hidden -File script.ps1I would...

View Article


Start-Process DirectoryNotFoundException

Good day. I want to remotely run a Windows update from 1809 to 1903. If I enter commands one by one, the computer will reboot and install the update. Here are the commands that I enterEnter-PSSession...

View Article


I have a script works on a Windows 10 Pro Computer but not a Windows Server...

First I do have powershell 5.1 installed on both. Second I do have .Net Framework 4.7 on both. Script works without error in windows 10 Error on Server 2012 R2 VM: Exception calling "DownloadFile" with...

View Article

Working with multiple or single email address

I need to preface my question by saying I am a beginner when it comes to PowerShell... that said, I need help.  Here is what I am trying to accomplish:  I have a script I built that runs tasks and at...

View Article

Using a Variable as a filter in a Where-Object

I have been trying to figure this out... I have a folder structure that I need to be able to pull up contents of based on user input. I have a folder named "Folder1" (for this purpose). and inside...

View Article

Update, insert, and delete statements for Powershell and MS Access file

Hi all!I have this MS Access file which I've been able (via an tutorial) to retrieve records from.However, I have not been able to find any article on how you can update, insert, and delete records to...

View Article


Is SMB1 enabled on our Windows servers?

How to use PS to create a SMB1 report on Windows Servers? 

View Article

Outlook client Powershell Script to delete mail including Conversation...

Sorry, I'm a newbie to powershell, I have found some code and pieced it together to get this far...but this code for outlook 2010 has errors and I don't know how to clear the conversation historyMy...

View Article


getting local admins form remote machine into csv cell

I use invoke-command to get a list of local admins from remote systems that I'm then trying to place in an Excel's cell and failing. Problem is that my custom property which is a hash table has all the...

View Article

Powershell output from Get-ItemProperty - VersionDetails property of file...

Hi, Recently we needed to get the version of mpio.sys one of our servers. I used Get-ItemProperty in Powershell to get the version, but when we browsed to the mpio.sys file in Explorer and looked at...

View Article


make one checkbox disabled while another one is checked

Hello,I woud like to make one checkbox disabled if another one is checked and vice versa.I do something like that:$pageFileCheckbox = New-Object System.Windows.Forms.Checkbox $pageFileCheckbox.Location...

View Article

Image may be NSFW.
Clik here to view.

use powershell to work with dcdiag

Hi,I find the following script to work with DCDIAG in english environmentfunction Invoke-DcDiag {    param(        [Parameter(Mandatory)]        [ValidateNotNullOrEmpty()]...

View Article

Powershell Script Automation

I have a script that connects to an SFTP location and synchronises a remote and Local location.  This works like a dream when i run it manually 100%.I need to run this script every 15 mins and as such...

View Article
Browsing all 21975 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>