Strangeness with looping through flowlayoutpanel controls
So I have a PowerShell tool that uses WinForms GUI.The GUI has one main flowlayoutpanel that in turn has roughly dozen flowlayout panels as child-items. These flowlayoutpanels contain groupboxes that...
View ArticleHow to enter password in the Sharepoint Login Popup
Hi,I am trying to automate the login for SharePoint currently. This is my code - $pwd = Read-Host 'Enter password' -AsSecureString #gets password from userStart-Sleep -Milliseconds 1000$ie = New-Object...
View Articleformatting issue
I have this code which works. But the format is not what I want. The format has distinguishedName, description and displayname on separate lines. $sourceOU1 = "OU=Physicians,OU=MGH...
View Articleexport-csv not working as I expect
I have the following code that I thought was going to write the values of the array of arrays or the array but in both cases, the results I'm getting are confusing to me (results look like attributes...
View ArticleSorting issue in import-csv
I have CSV file contains below data. I am not able to sort the numeric data (with couple of string included) as desired. Percentage99.9110099.96NoObjects10010099.9499.61 When I use the below...
View ArticleHow to resend an email if send-MailMessage fails?
My company's SMTP server is a little wonky. Every so often when I send an email to it from Powershell it will fail because the STMP server refuses the connection. I'd like to create some Powershell...
View ArticleUse Group Policy to provide users a standard Windows 8.1 Start screen
One of the big problems with Windows 8 was that there was no easy way to enforce a consistent Start screen for end users. Microsoft has addressed this problem with the Windows 8.1 Start screen, and it...
View ArticleScript to find SMTP addresses with #2 after them
Good Day all, I am running Exchange 2010 in my environent and as you know if you create an address for a user that already exists it will create the account with First.Last2@my domain.com.Is there a...
View ArticleExport user where the name is not the same of the givenname
Hi I want to export the list of my users but only the one that don't have the same givenName and the sn. Because I have generic users so I don't want them in my list Get-ADUser -Filter * -Properties *...
View ArticleLog File Processing - How to get PowerShell to remember where it last read in...
Hello PowerShell Experts,I'm looking to implement a log file monitor on a Server 2008 R2 system that watches for out of memory conditions. Searching a log file for a string of text is no problem. Got...
View ArticleSeeking Performant Filter On Many Items
Is there a more efficient way to filter thousands of items from a SharePoint library than this below?$FilteredListItems=$list.Items | ?{$_["CustNum"] -eq$currentCustNumber}Scenario:• I am exporting...
View ArticleDelete last occurrence of a string in a file
Hi,I'm using PS to generate some SQL files, a bunch of them being multi-table inserts. How would I delete the last occurrence of UNION ALL in my files?Thanks
View ArticleGetting SQL Server Performance Data with PowerShell
Once you've got your SQL Server environment set up and working the way you want it, it's time to start gathering your baseline performance data. A baseline is critical because every workload is...
View Article4 Essential PowerShell Provider Commands for SQL Server
Windows PowerShell commands can be a valuable addition to your SQL Server management tools. Although I don’t think PowerShell is going to replace SQL Server Management Studio (SSMS) anytime soon, it...
View ArticleAdd a Progress Bar to a Graphical Status Box in PowerShell
Jeffrey Hicks shows you how to build on the code from a previous lesson to add a progress bar to your status box.Read More
View ArticleRunning commands simultaneously
I am trying to create a Powershell script that will run multiple instances of Robocopy at the same time. Is there a cmdlet in Powershell that will do that?
View ArticleSet Powershell Execution Policy via Batch script?
I finally finished a big Powershell script, learning Powershell all on my own via the Internet, to "build" a Windows 7 PC that has only the operating system and an Administrator account. My script...
View ArticleCreate computer accounts from csv
Hello my first post here looking for help creating multiple ad computer accounts from a csv file. We also need a specified password set using the accountpassword field. Would anyone one have or be...
View ArticlePower Shell vs AutoIT
How does Power Shell compare to AutoIT in terms of:1. functionality2. complexity 3. learning curveCurrently my interest is for non-GUI functionality, especially for disk/folder/file management, PC...
View ArticlePowershell script to Install Certificate in Active Directory store
Hi Everybody!I'm trying to write a powershell script to install a certificate into the active directory certificate store,Here are the steps to do this manually, any help would be greatly...
View Article