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

Creating Local (non-domain) admin user on remote computers

Hello,We are working with moving a number of our virtual servers and once the migration is completed for each server, the server is not on the domain so local admin access is required to get it back on...

View Article


Override Default Error Message in Function Parameters

Hello ,          Is there a way to override the Default Error Message that i get for a validation error in parameter that i being passed by the user. In most of the cases the user will not be...

View Article


Event Handler Between Reboot states using Powershell

Hi,I need some help writing an event handler for a powershell script that would meet the following requirement:1.  Continue Upon a restart2.  Continue Upon a sleep state3.  Continue Upon a hibernation...

View Article

WPF UI application using powershell cmdlets

Hi,I plan to create a C# WPF UI application which uses my own powershell cmdlets to do all the works like adduser, addgroup, getmachineinfo...I have foresee some issues in this model. For example,...

View Article

How to get all records using Invoke-webrequest?/Why Invoke-webrequest returns...

invoke-webrequest content returning only 2000 records though it has around 4000 records in web api. The same url if I give in excel oData Data feed I am getting all the records. See the below script...

View Article


Last added to Security Group

Hello All, i am trying to get the last added users to security Group X but i don't know how to achieve this ? anyone worked with solution before ?any help please ?

View Article

Excell empty cell

Any idea why below doesnt work???$virtualNetwork = $csdWorkBook.worksheets.item("Virtual Network")$test=$virtualNetwork.cells.item(4,7)  #check if this cell is emptyif ($test -eq "") { write-host...

View Article

WSUS and PowerShell

Hello Everyone,       I have a Windows 2008 R2 WSUS server with WSUS 3.0 sp2 installed. Recently Microsoft released an update for the IE vulnerability (KB2964358) which affects all versions of Internet...

View Article


Check if drive exists, If not map

I want to check for the existance of a drive mapping (called X in this example) and if it does not exist, I want to map it. Here is what I have so far:$driveCheck = Get-PSDrive | Where-Object { $_.Name...

View Article


Exchange Edge clone config import in Exchange Management shell throws error...

Hi All,During the Coexistence of Exchange 2007 to 2010 Migration..I have create new Edge Scubscription in Edge Server 1 and Export the Edge Configuration File from Edge Server 1.While trying to Import...

View Article

Run Powershell script as Scheduled task, that uses Excel COM object

What am I missing here.. I have  Powershell script that uses the Quest AD cmdlets to get computer information from AD and populate an Excel spreadsheet with the data.The script works fine, so I created...

View Article

IE & powershell

hi everyone,i try to add a website as trusted into internet explorer and at the same time authorize all the ActiveX option on all the trusted websites... actually i added the website to the trusted...

View Article

get-messagetrackinglog Distribution Group Expand Group

Hi All,Is there a way, to get the logs form a Distribution Group. I would like to view the users that were in the group at the time the email was sent?The below command is useful, but I would like to...

View Article


32 bit vs 64 bit odbc connection problems

Good morning,I am trying to connect a powershell script that worked fine on a 32 bit system, but now will not work on a 64 bit system.  This script connects to a odbc connection and connects to a...

View Article

Powershell is auto logging me into website?

I ran this code and it allowed me to login to the website and it downloaded everything into a text file, but after the first try it as been giving me an error: "Property 'value' cannot be found on...

View Article


Pin items to Windows 8 Taskbar

Guys.I found this powershell function on the internet for adding items to the taskbar on Windows 7\8 The function works fine when running it against a single itemfor example Pin-Taskbar -Item...

View Article

Script will not work

Hello,I am running this following script:-# Bulk Mailbox Export for users selected from CSV File   # Script Starts here $Users = Import-Csv c:\users.csv   foreach ($Users in Import-Csv ./users.csv) {...

View Article


If statement to join users to AD groups

Hi All,I'm trying to create a script that does the following:1. Copies AD group memberships from a source user to the target user2. Checks whether the target user is a member of GroupA or GroupB3. Then...

View Article

Add domain user as sysadmin in SQL Server 2012 using PowerShell

Hi,I am using the following PowerShell script to add a domain user to SQL Server 2012 as sysadmin, but I encounter an...

View Article

Script for Moving List of Computers to OU

I have a list of computer names in Excel. I want a Power Shell script, or any other type of script, that can grab that list of computer names, and move them into a specified OU.The OU's name is...

View Article
Browsing all 21975 articles
Browse latest View live


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