Problem Combining csv files
Hi there my Powershell collegue is on holiday and he gave me the idea to look into powershell hashes to created the report I want. I will try to explain here what I want and what I already retreived...
View ArticleIf else condition not really working.
As part of a script which i am writing, i have a small section for emailing results of the execution to couple of us. I put a if else condition so that we get mail only sometimes when the condition is...
View ArticleNeed some help with parsing this txt file into a CSV format
Hello Everyone,What I am trying to do is take this .txt file and convert it to a .csv with the AD group in column one and the users for each group listed next to it in column two equally matched in the...
View ArticleModifing HomeDirectory Settings
At the college I work at we are removing the students H: drive and I believe I have the correct powershell script to do that. set-aduser -filter * -searchbase "ou=ouName,dc=domain.dc=local) |...
View ArticleHelp formatting a txt file to output to a HTML Report
I'm in a scripting class online and I'm having a hell of a time formatting a txt file and outputting it to HTML with Power Shell. I need to render the HTML report with all the information from the txt...
View ArticleNeed to Process 12 Files parallel using Logparser
Hi All, I am trying to use Logparser to insert IIS log data into SQL on hourly basis. However, I have an issue with the duration it takes to complete one hour data. This way i am lagging behind on...
View ArticleCheck latest file and download
Hi all,only just getting started in powershell and have come up with a question.I have the following script that downloads a file from a sharepoint server.$storageDir =...
View Articledifferents between system.directoryservices.activedirectory.domain and...
Hi, i would like to ask, what is the differents between following classes ?[system.directoryservices.activedirectory.domain]::getcurrentdomain() and microsoft.activedirectory.management.domain...
View Articlewin32_product not returning anything
Hi!Just started to learn powershell and I think I'm loving it :-) Anyways, trying to make a script to determine what roles are installed on a server. And if the roles are missing then install them.I've...
View Articleerror while adding user in local policy
Hi, Below is my script to add user into local policy using powershell script:#********************************* AddUserRights Function AddUserRights {...
View Articledetermine which network drive is mapped in user computer
hi, i have a domain environemnt. I 'd like to determine which network drive is mapped on domain user computer. (i use domain admin account). I type : get-wmiobject win32_logicaldisk and use drivetype=4...
View ArticlePowershell & C# to check if host available
Hi All,I have a c# code segment which process a power-shell script. The following is the code segment. Runspace objRunspace =null; objRunspace =RunspaceFactory.CreateRunspace();...
View ArticlePowershell xml insert parent tag around all siblings?
<root> <parent> <child1> ... </child1> <child2> ... </child2> </parent></root> i would like like...
View ArticleWhy can't I pass a string variable to the -Query parameter when using...
shouldn't this work?$this = "select * from win32_service where name='WinRM'"Get-WmiObject -Query $thisI need to build a query string by supplying a variable. I've tried various ways to include the...
View ArticleUsing Powershell to Manage Hyper-V Integration Services in Server 2012 R2
A while back, Eric Siron, one of my fellow Altaro.com bloggers, did an excellent write-up regarding Hyper-V integration services. Said post did a great job explaining the need for integration services,...
View ArticlePowerShell module management as a native feature is here!
PowerShellGet is a new way to discover, install, and update PowerShell Modules. New in WMF 5.0 Preview May 2014, PowerShellGet contains a set of cmdlets that enable users to interact with an online...
View ArticleDSC your workstation to test Windows PowerShell JEA in Azure.
Calling all Azure fans! Paid subscriptions, trial accounts, and MSDN SUBSCRIBERS. Don’t forget, if you have an MSDN subscription you have credit to use for testing in Azure!Read More
View ArticlePowershell CSV report usernames & Phone Numbers - but exclude area code?
HowdyI am working on a PowerShell report of user names, First, Last, and their phone number populated in AD.But the request is to take out the area code. That's not something I've done before, can...
View ArticlePowershell v.2.0 to v.3.0
Hi all, We recently updated one of our admin servers to WMI 3.0 and I'm finding that all my PS v.2.0 or earlier scripts are no longer working. Does anyone know how to write a command within the script...
View ArticleFinding exactly four numbers
Hello all, I have a CSV file that I want to find exactly four numbers. I do not want any numbers with any more or less than four numbers. I also do not want four numbers attached to any...
View Article