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

Returning employeeID property with System.DirectoryServices.DirectorySearcher

Due to some constraints as to where the script will be used, I'm using the ADSI method to dump out a user report. It needs to include the employeeID.$filter = "(objectCategory=User)" $ou = New-Object...

View Article


PowerShell - Set Zone Transfers on Secondary DNS Zones

I've a few hundred zones that I need to update the zone transfers on, a mix of primary and secondary zones.I can find a way to update the primary zones with the below:[CmdletBinding()] Param(...

View Article


Invoke-WebRequest property, analog of "LocationURL" one of...

Is there Invoke-WebRequest property, analog of "LocationURL" one of "InternetExplorer.Application" ComObject?Example: $ie = new-object -ComObject "InternetExplorer.Application"#some...

View Article

Powershell Notification of users about the expiration of the certificate

It is required to notify the user about the expiration of his personal certificates. I found the user's logs and his certificate. # I define the user login     $user = $env:Username  # By login I...

View Article

Returning ANY property with System.DirectoryServices.DirectorySearcher &...

OK, so there is this old thread -...

View Article


Login button click script not working in IE

Hello thereThe script is not throwing any errors but i am unable to automate login to website(Its automatically entering my username and password though but not clicking the Login button)HTML...

View Article

how to include streamwriter

  I've been searching on how to include streamwriter since this file I'm do a replace in is large and want to as fast as possible create the new output file. $Start = Get-Date # # Start # $LogFilePath...

View Article

How to remove an Azure Account from Powershell and Login with a new account

I am using the command Remove-Azureaccount to remove a current existing account attached to a particular subscription and I would like to login with a new account to see some other subscription.Both...

View Article


New-ADUser Script Help

I want to create a portion of the script that checks if the samAccountNameexists based on the givenName and surName that is entered at the beginning of the script. If it does, I'd like to have the...

View Article


Powershell OCR

I would like to be able to script OCR against a jpg.I have tried installing MODI from office 2007 / 2010, but had no luck.I read that Windows now has OCR available for UWP applications. is this in any...

View Article

Third Firday of the month

I need to reboot a few servers on the 3rd Friday of the month but I'm struggling with the PowerShell commands. Anyone able to assist?

View Article

stop the script when var ProfitThresholdToStopScript = 50 how can i solve this

   var config = {}; // ------------------------------------------------------------------------------------------------------------------------ var BaseBet = 40;           // Set the base bet here. //...

View Article

Change Job Titles in AD via Powershell

HiI am running the following script in an attempt to update over 500 user job titles within Active Directory:Import-CSV -Path C:\Users.CSV | Foreach-Object { #properties from the csv    $mail  =...

View Article


Image may be NSFW.
Clik here to view.

Powershell Skype Online Session does not work.

I try to use Skype Online Session but it does not work. Any ideas what to do? I have tcp/443 connection on a place. And credentials are working fine.

View Article

Powershell Scheduled Task; Encrypted Password: Key not valid for use in...

Hello everyone!This is my first post in this forum and I'm looking forward to it!Anyway here's the problem. I got a Powershell Script which I want to implement in the Task Scheduler. The script...

View Article


get all places of URL usage

Hello guys,is there a way to find out all the places where a specific URL is used by using PowerShell ?I tried it this way:Add-PSSnapin "Microsoft.SharePoint.PowerShell" get-spsite -limit all|...

View Article

a lot of cmdlets missing from powershell

The o/s is windows 2012 R2. When I am trying to manage some of the tasks about Active Directory such as bulk user password and bulk user import, a lot of cmdlets are missing. I did type "import-module...

View Article


Sidhistory

Hi,For migration project, need to see how many users were migrated. Is there a script for pulling sidhostory for all users from a  text file or an OU? 

View Article

Using an environment variable with a "."

An environment variable exists on all our machines that has a period in it, as in "abc.xyz".PowerShell chokes on $Env:abc.xyz. PS C:\Windows\system32> ? $Env:abc.xyz Where-Object : Cannot bind...

View Article

New-PSDrive error with double hop

I'm trying to install software from a UNC share path, executing a script from serverA, to install the software on serverB.  The install executables will be called over a UNC share on serverC - your...

View Article
Browsing all 21975 articles
Browse latest View live


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