Quantcast
Channel: The Official Scripting Guys Forum! forum
Browsing all 15028 articles
Browse latest View live

Windows PowerShell utf-8 encoding

Hello!I would like to know if it is possible to configure Windows PowerShell to print utf-8 characters?I searched the web and found multiple solutions, but nothing seems to be working.e.g.:* chcp...

View Article


Problems with VBScript

Hello everyone!I got a bunch of Windows 10 LTSC 2019 systems that operate like a Thin Client. I have a Custom User Interface GPO set currently that launches a custom RDP file on login and it works...

View Article


PowerShell Invoke-Command format and export output

I have a list of computers that I am checking if they are online.  If they are online I am storing them in the variable $onlinesystems that I use invoke command to check if a Registry Key is present...

View Article

How to update windows Defender Anti-Virus definition using Powershell?

I would like to update windows Defender Anti-Virus definition without updating windows using Powershell.Windows update would be done manually.Does anyone have any suggestions? Thanks in advance for any...

View Article

Remote restart computer script with user interaction

Hi Support,As we are checking the a remote restart PC script for restart user’s PC with user prompt up. I tried both psshutdown and shutdown commend.Both command is able to restart, but we hope to have...

View Article


Powershell Add-PrinterDriver for a driver that is not on the remote machine

   I am trying to install a HP universal print driver on about 5 server 2012 computers.I could do it one at a time seeing how it is only 5 or so but I thought this would be a great experience to do so...

View Article

ForEach Statement only returns one value

Hello,I've written this PS script to return multiple values from a 'Get' command and place those values into an INSERT statement.  However, it will only return one record instead of multiple.$billing =...

View Article

Powershell to group by date time

I wrote below powershell script: Get-MessageTrackingLog -Start $start -End $end  -ResultSize unlimited -EventId Send | select $_.Timestamp.ToString("MM/dd/yyyy"), $_.ReturnPath It give me error You...

View Article


foreach loop

HiAm trying to rename my files in such a way that all the files in $filenames are renamed with names in $lastname and $firstname variables.to achieve this am using for ForEach loop in here , but the...

View Article


Script to SILENTLY Uninstall Chromium Edge BETA or DEV

Do you have a script (PS or CMD) to uninstall CrEdge Beta?I am ready to deploy the RTM version of CrEdge, but that install does NOT uninstall the Beta or Dev versions which I have on dozens of Win10...

View Article

Image may be NSFW.
Clik here to view.

Powershell - loop question

I have a script which is visible in the screenshot and I don't know why the values in $vmlist cannot be accessed. I'm creating the list, then foreach"ing" them, but running a command against them is...

View Article

Add Users from Trustet Domain

Hello,We have two Domains with a trust between them.Now we want to copy users from one AD-Group to another:Get-ADGroupMember Group1 | Select sAMAccountName | ForEach { Add-ADGroupMember Group2 -Members...

View Article

Is there reference documentation for the JScript language used within Windows...

I posted this topic in the Windows 10 General forum.  That resulted in my inquiry used as the title for this post along with the suggestion that this was the place for asking such a question.

View Article


Getting error when adding psobject in array

Hi All,I am creating a GUI tool using PowerShell. $data_array = @() $precheck.Add_Click({ foreach ($server in $serverlist) { $status_data = Pre-check -serverlist $server -datapath $datapath -logpath...

View Article

How can files be gather from folders, subfolders from windows paths, copied...

Please I need assitance on how to:- Create folder with random folder name to windows variable path [%appdata%], - Gather files such as [".fileextension1",".fileextension2"],from All Folders, Subfolders...

View Article


How can files be gather from folders, subfolders from windows paths, copied...

Please I need assitance on how to:- Create folder with random folder name to windows variable path [%appdata%], - Gather files such as [".fileextension1",".fileextension2"],from All Folders, Subfolders...

View Article

Set "Run Whether User is logged on or not" setting in a scheduled task

PowerShell allows a lot of switches, but none seem to apply to  "Run Whether User is logged on or not" which for me is the most important because I create scheduled tasks to run when I'm not logged on....

View Article


Creating a single computer Managed Service Account (MSA) for scheduled tasks

I have managed to figure out the steps for creating the MSA. And I have used Test-ADseviceAccount and Get-scheduledtask to make sure all the pieces are configured. However, when I use the command shown...

View Article

Mount windows share in command line via net use with password encrypted.

Hi All,  I just try to do with this but not importing the password i think? Get-Credential | Export-Clixml C:\Users\user\mycredfile1.xml $Credential = Import-Clixml C:\Users\user\mycredfile1.xml net...

View Article

Install script: Resume after restart?

I'm in the process of automating recompose process for VDI. where there is a requirement to resume powershell script where it left off. Ex: I want to move the computer from domain to workgroup and...

View Article
Browsing all 15028 articles
Browse latest View live


Latest Images

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