Basic question: How can I automatically lower the execution-policy (admin...
I want to run this script on a couple of machines that have a default executionpolicy restricted (which is fine by itself): Set-ItemProperty -Path...
View ArticleReplacing 0 with +44 in mobilephone attribute AD
I am attempting to change the mobilephone attribute of all ad users. If the users mobile starts with a 0 the 0 needs to be replaced with +44 if it doesn’t start with a 0 then nothing needs to happen....
View ArticleI’m presenting tomorrow! PowerShell ❤ SQL Server: Modern Database...
submitted by /u/thebeersgoodnbelgium [link] [comments] The post I’m presenting tomorrow! PowerShell ❤ SQL Server: Modern Database Administration with dbatools & dbareports appeared first on How to...
View ArticleCheck if AD users have a thumbnailPhoto
This what I thought was working until I checked in outlook. Import-Module ActiveDirectory $AllUsers = get-aduser -filter { objectClass -eq "User" -and Enabled -eq "True"} -Properties SamAccountName |...
View ArticleDoes this really not exist in powershell??
submitted by /u/ewright049 [link] [comments] The post Does this really not exist in powershell?? appeared first on How to Code .NET.
View ArticleNeed some regex help
We have daily queries from our user databases that we use for terminating user access. Normally, we take this data and paste it into Excel and save it to CSV for later use. I’m trying to automate the...
View ArticleParsing Errors Help
Line 13: You must provide a value expression following the -like operator. Line 13: Unexpected token @domain.com in expression or statement. Line 13: Missing closing ) in expression Line 13:...
View ArticleMildly annoying a colleague
For any of those who use PowerCLI, I thought I would share what I consider my favourite bit of code. Create the file Initialize-PowerCLIEnvironment_Custom.ps1 in the scripts folder of a colleagues...
View ArticleRemotely changing PC’s “Owner”, “Description”, and “Organization”?
I used to have a batch file that changed all of this pretty easily. You just run it, give it the computer name, the user name, and it changes all of the appropriate reg settings. I’m having trouble...
View Article[Question]Update WPF ListBox Items based on user input.
I’m having trouble on how to go about filtering the list of AD groups that show, imported CSV, based on what the user types. I start by populating the listbox which works fine. The issue comes when...
View ArticlePowerShell question for a lab
Hi Reddit, I didnt know where else to post this, so if theres a more appropriate place, please direct me to it, TIA As written in the image (imgur link below), I need to use get-help for...
View ArticleAdding | processing to an existing PoSh module
I am wondering just how hard it would be to edit an existing PoSh module that has ~100 cmdlets to add the ability to pipe command ouputs to each other. Currently none of them support it. If I save the...
View ArticleGoing nuts checking for software on a remote system!!
Hello, I am trying to check if some software is installed on a remote system. I can get it to work if I do all the work inside of a ScriptBlock but if I try and do anything outside of the ScriptBlock...
View ArticleHPE StoreOnce PowerShell Module Version 2
submitted by /u/vMarkus_K [link] [comments] The post HPE StoreOnce PowerShell Module Version 2 appeared first on How to Code .NET.
View ArticleRename folders Lastname, Firstname to Username from AD
Does anyone know how to rename a bunch of folders that have “Lastname, Firstname” to “Username”? It would have to do a lookup in ADUC and convert Lastname, Firstname >> Username for each folder...
View ArticleHow to access a webpage behind Cloudfare with PowerShell?
FYI, I am new with PowerShell so don’t know much. readcomiconline.to kissmanga.com These websites supposedly are behind “Cloudfare” From here Because readcomiconline.to is behind CloudFlare, there’s a...
View ArticleXML struggles
I am trying to interrogate multiple xml files with powershell but struggling to read some information out. I have read the xml file in to $xml2 variable. I run the following to get into the correct...
View ArticleSQL Output to CSV; send email and Slack Message
Decided to share my first proper(ish) Powershell script. Any critiques would be great https://gist.github.com/Fysi/ccf3d9bafed3309296d22fd652f4beba submitted by /u/Fysi [link] [comments] The post SQL...
View ArticleCreate LDIF backup from CSV
Good morning, I am attempting to create an AD LDS LDIF backup for specific users listed in a CSV file I have (it only contains their DNs). Is there a best approach on how to do this? I was thinking...
View ArticleCreate a price chart of Bitcoin from the last 30 days
submitted by /u/nickrod518 [link] [comments] The post Create a price chart of Bitcoin from the last 30 days appeared first on How to Code .NET.
View Article