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

Problem with EnumKey "Object Not a Collection"

The purpose of this script was to allow me to quickly change the WSUS intranet server (I'm not fully done with it yet), instead of using the local Group Policy. Sometimes the WindowsUpdate key does not...

View Article


Problem installing printers with VB

Hello All,I hope you guys can help me with a problem i have. For a customer we are trying to install printers via a script executed at login. We got it working on 32 bits workstations, but i wont work...

View Article


Powershell script to get the last 2 characther of server name and pass it to...

Hello Guys,Im looking for a simple solution to find the hostname, and then select the last 2 characters and pass it to a variable?Ive been searching the internet the whole day.. but no success..Trimend...

View Article

Getting information and piping it to a set command

Hi,I really don't know PowerShell very well, but what I would like to do is get some information about an object (a particular piece, or two) and then use that information in a set command.I would like...

View Article

How to check/uncheck "Automatically update e-mail addresses based on...

Hi All, I figured out how to get a list of email enabled user objects that have the "Automatically update e-mail addresses based on recipient policy" checkbox unchecked. The following ldap query...

View Article


Powershell Get-Aduser

Trying to write a script that will check whether a few accounts are enabled, locked out, and return the last password reset time.  Any reason why $User.LockedOut or $_.LockedOut will not return a...

View Article

Script for renaming multiple workgroup computers in LAN remotely based on MAC...

Hii Please help me in  Scripting for renaming multiple workgroup computers in LAN remotely based on MAC Address by passing MAC and New computerName through a file in in one shot  File...

View Article

Locate files using a vb script

Hi everybody, I am a network guy with 0 programmings skills :) I'm getting better with scripting slowly but surely...I have a customer that needs to find where are located Groupewise archives for...

View Article


Dynamic Printer Mapping by Location with configuration file

Hi everybody,i'm looking for a script thats mapping printer by location (ip adress) which is controlled by a configuration file, where the shared printers are defined. Unfortunately I could not find...

View Article


Problems with the wait-job

Hi guys, first question in this forum.I have created a script for backing up file-stores and databases, then copy the content into a zip-file.I really want the powershell window "sleep" while the...

View Article

Parse XML file

Hi,I'm new to PS and I'm trying to parse XML file that contains full config of DPM protection. The structure of XML is not like DB.I need just some of the elements and attributes and not all of...

View Article

How to simplify complex PowerShell if statemant?

Good morning,please any idea how to simplify following complex PowerShell if statemant?if ($child1 | Where-Object {$_.operatingsystem -notlike "Windows RT*"} | Where-Object {$_.operatingsystem -notlike...

View Article

Issue using powershell to get computername to use in a variable

I am having an issue getting the correct value from Powershell when using this:$ComputerName = env:computername $FileName = $ComputerName + ".prefs"When I do that, I get the value of MOST of the...

View Article


Help with Script created to check log files.

Hi,I have a program we use in our organization on multiple workstations that connect to a MS SQL 2005 database on a Virtual Microsoft 2008 r2 Server. The program is quite old and programmed around the...

View Article

Get-ADUser : The server has returned the following error: invalid enumeration...

I'm running a powershell command to add the email (AD mail) attribute to users in a specific OU.  It seems to work then will bomb out with the error in the title.I'm using a "scripting guy" command...

View Article


Script to Scan for .PST files

Hi All, Please I need a script to scan the local drives of  a  computer for PST files  and then create a folder with the computer name,Copy the found PST's to a share on the specified network.  I found...

View Article

The scritpt makes the GET, but does not do SET to change the attributes

This my Script.The script excuta without errors, but does not change the attributes, help-me please=================================================Get-Command -Module ActiveDirectory  $users =...

View Article


Psexec and UAC

Hey, I am trying to remotely enable powershell remoting in a powershell script :) In the past i did it like the following:$Directory = Split-Path $MyInvocation.MyCommand.path $CompName =...

View Article

PowerShell: How To Reset Domain Account Password for Multiple Domains

Hi All,I am trying to find a way to use PowerShell to reset the password for my domain user/admin account which resides in multiple domains. It is also a requirement not to use any AD cmdlets, as this...

View Article

Configure service with Set-Service

Can I set a service to run in its own container thru Powershell? ie. What is the Powershell equivalent of sc config <service name> type= own

View Article
Browsing all 15028 articles
Browse latest View live


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