PowerShell Word Table headings
HiI have a script that creates a word table whose data goes over 2 pages. I would like to have the header row at the top of each page. Can anyone help please?
View ArticleCreate Volume
Is there a way to create a new simple volume on a basic disk using Powershell?
View ArticleScript to retrieve AD CA issued certificates
Hi there, I have the code below that I can point to my local Active Directory Certificate Authority and it will pull back expiring certificates, based on a set number of days.How do i run this script?...
View ArticlePowershell List Box Items to Execute Active Scripts
Hi, I'm just starting to brush on the topic of creating simple GUI's in PowerShell. What I want to accomplish is to create a list box list of items from maybe a CSV or an array and then have each one...
View ArticleAdd-ADGroupMember : A referral was returned from the server???
I'm sure I'm missing something here...All I want to do is add a user from a child domain to a universal distribution group in a parent domain. Sounds simple enough right? WRONG!Here is the example...
View ArticleList print queues on workstations
Hello,I am trying to write a script to list all the printers defined on a workstation (local and network). I was successful listing the local printers but I can't find a way to list the network...
View ArticleMerge multiple CSV files with a join on the Name column and rename other...
Hey guys can anyone help me with this, I need a Powershell script to join multiple csv files together but am getting nowhere with it.Basically I have multiple csv files which all have a Name column a...
View ArticlePowershell connection did not being closed/disposed in windows service.
I have a service that makes powershell connection to the server to execute cmdlets. In the test lab, it opened connections, executed cmdlets, then closed/disposed connections without any issues. It...
View ArticleCannot run an exe file in RunOnce
I put a ps1 file in HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce on a Windows 7 PC with powershell 1.0The file include a few exe files. After logging in, the ps1 script run all the exe files...
View ArticlePowershell setting NTFS rights and security groups.
Hi All. I have been working a few hours now trying to make the following script that would work like this:You type in a path for a folder on the network.It would read the name of the folder to a...
View ArticleLooking for good books on the Virtual Machine Manager Powershell Module
Hi, I am looking for a good book, or books that teach you about the Virtual Machine Manager Powershell Module for Windows Server 2012. I am looking for examples of the cmdlets, in addition to a...
View ArticleRunning msbuild.exe multiple times results in no return from command
I have a whole set of powershell scripts that we have used now for more than a year to do our Visual Studio builds and deploys. We have been running on a Windows Vista Pro 32bit machine but now are...
View ArticleUse Powershell to check whether and AD user exists
We're trying to clean up roaming profile folders, and as part of the task I need to check whether the user actually exists in AD. I have tried 3 different methods and so far none of them work.Either...
View ArticleTimezone of multiple servers
I need to check the timezone and time of different servers. I have written this script but not getting the output in a proper format . Can anyone help with the format .The script is:- $time =...
View Articlesend an email with output via powershell - color coded output
Hi Guys,i am trying to setup email notification. My script goes through our filers collects errors, warrning etc and sends the email.the script and email notification is working fine, the short version...
View Articlec# reading from text file
Receive two error1. The type or namespace name 'async' could not be found (are you missing a using directive or an assembly reference?2.The name 'await' does not exist in the current contextpublic...
View ArticleHow to link the output from win32_diskdrive and win32_volume
Hi,I am doing some analysis on multiple servers and am looking at ways to link the output from the following 2 lines:Get-WmiObject win32_volume | Select SystemName, name, Label, DriveLetter,...
View ArticleError using Invoke-SqlCmd
Receiving error using this script: The TSQL script runs fine but errors in powershell.Exception : System.NullReferenceException: Object reference not set to an instance of an object....
View ArticlePing bulk computers
1.Type and identifier are both required in a foreach statement2.The name 'lines' does not exist in the current contextpublic void Main() { try {...
View Articlewindows process/batch don't have status object unlike windows service
hi all,is there a way i could get the status of windows process or windows batch file? there's no status object unlike service that you could check for hung or stopped.thanks for any comment you may add.
View Article