Don't try this cool new command!
Dont' open PowerShell as an Administrator and run this:get-service | stop-serviceBest not to do it on the boss's laptop right before a big presentation.You're welcome.*this was obviously a bad idea,...
View ArticleBut on a more serious note...
I created my first useful script with a pipeline today!I'm just learning, so this was really satisfying.I'm really starting to love PowerShell.
View ArticleConvertto-html , carriage return in cells.
Hi everybody!I am changing a script that creates an html file with entries from a login / logout script, and I add two columns : Ip address and Mac address.The DHCP leases are exported from our...
View ArticleCombining to Powershell Commands - Where am i going wrong?
I'm quite the newbie at powershell commands.the commands are to disable Protect against accidently deletion and then move them to a particular OU.Seperately, each of the scripts work, however when...
View ArticlePowershell > get user's group membership, showing just name and groupcategory
How can Powershell spit out a report of a user's group membership, showing just the group's name and groupcategory. i.e. I just want to see the user's security group...
View ArticleHow to delete a folder, its subfolders and items in Outlook using Powershell?
I have a folder (e.g. Folder A) that contains 50+ subfolders. When I try to delete it from Outlook 2010, I can't do it because it contains items. So I have to delete the subfolders' contents first...
View ArticlePowershell classes? Any suggestions
I really want to improve some areas of our infrastructure that could definitely use some automation. I have always enjoyed using the bit of powershell I know but I feel like we can do so much more with...
View ArticleHELP With Scrip to import Bulk Users to AD (server 2012 R2)
I wrote the code below and i am trying to import for a CSV file.. but every time i run it , ti tells me the followingNew-ADUser : The object name has bad syntaxAt...
View ArticleHow to search and delete in the registry with PowerShell?
OK, so I know how to delete, and add, etc, but to search and then delete according to results that is a little bit more difficult for me :)Here is the reason, we lock the desktops using Deep Freeze,...
View Articleif folder path not found get back a popup
Dear all, I need a batch file or script for the purpose -I want to confirm a folder path in program files for all systems, I want to confirm the program availability on the systems. I want to run the...
View ArticleIssues with Powershell Script!!! Help!
Hi GuysIm a little bit new using power shell, Im trying to run a report, that provides me all inactive accounts/computers on my network, I found something but when I try to run this...didn't work at...
View ArticleRunning into error using set-aduser to update Active Directory attributes
Hi there,This is my first time posting here, but I thought I could request some assistance with a Powershell scripting issue that I have been running into for a number of days now.I'm attempting to...
View Articledelete files by date and character count
I have an interesting problem. I need to delete directories that are older than x days but are only numerical. We have a log folder that has log files that we need to delete but other files and folders...
View Articlepowershell: need to strip out first x number of characters on each line
I have a txt file with over 2 million lines, i need to remove the first 45 characters of each line so i can turn the txt file into a usable filename list for another script to work out of. a section of...
View ArticleScript to bulk import groups and contacts for Lync2013
Does anyone have a script out there that will allow me as the administrator for our Lync 2013 Server to administer the groups and contact lists in Lync 2013?I have seen Contact Manager for Lync by a...
View ArticlePowershell script to modify Office and Dept
I have a file with Samacountnames, office locations and dept. I need to run thru powershell so that it finds the users and updates their ADUC . How can i do this with powershell itried doing this but...
View ArticlePowerShell script - error regarding ampersands
I'm working up a powershell script to do some registry modifications. But I'm running into a problem on my first line. I'm sure its something small, but I'm just completely missing it. Anyways, here is...
View Articlescript to edit folder permissions based on folder name
Hi All, hope someone can help as this is driving me around the bend and back again...i need to edit the permissions on a shed load of folders as they weren't set up properly...what we have is a setup...
View ArticleRun a command on remote machine using powershell
hi,I have a command to be executed on a remote machine using powershell. (Had tried using PsExec. But can't execute commands on a remote server (web server) as it was not shared over network.I have the...
View ArticleAutomatically and silently bypass Execution Policy for a Powershell script?
I have a script that makes a folder structure. It runs fine when run from the file server, sometimes asking to bypass the execution policy then it runs.However this script needs to be run by certain...
View Article