Matching part of a file to a list of folder then moving it
I’m 100% new to this and I am mainly working off of examples I find similar to what I’m trying to do along with the obvious trial and error. This is my first attempt at a powershell script to sort...
View ArticleDSC Resource Kit Release February 2018
submitted by /u/PowerShellChallenge [link] [comments] The post DSC Resource Kit Release February 2018 appeared first on How to Code .NET.
View ArticleIs DMX in jail ?
Link: https://github.com/oboily/IsDMXInJail/blob/master/isdmxinjail.ps1 function IsDMXInJail { <# .SYNOPSIS Is DMX in jail ? Good question! .DESCRIPTION Return True if DMX is in Jail .EXAMPLE if...
View ArticleScript to extract attachments from saved outlook files
Hi all, I need to use PoweShell for a work project, where I need to extract the attachments from a bunch of outlook email files, saved to a folder in someone’s c drive. I am not very experienced with...
View ArticleAuto Domain join (double click and done)
I have spent about 2 hours now looking on google for a solution to auto-join a pc to a domain with powershell (without having to type in your password) all of them fail when I try to use them on my...
View ArticleExport-csv blues
So I made a script to save me a bunch of time when they want a new user’s permissions to mirror a current user’s: pastebin But my output’s messed up. Instead of outputting the name of the groups, it...
View ArticleAnyone know how to set the position of the legend in a chart with PowerShell?
I’ve been at this for most of the day so far and am coming up empty. Finally ready to ask for help. I am able to create a bar chart with three series of data as intended. Looks nice, if I say so...
View ArticleRemotePrintersWithErrorsToCSV
submitted by /u/Evelen1 [link] [comments] The post RemotePrintersWithErrorsToCSV appeared first on How to Code .NET.
View ArticleTrouble understanding expanding variables in script blocks
Hey folks, I’m having a bit of difficulty understanding variable expansion within scriptblocks. I have the following: $script = ‘$(hostname)’ I want to use this in a command to run a script on a...
View ArticleSCCM Content Distribution Scheduler v2.52
submitted by /u/Fendulon [link] [comments] The post SCCM Content Distribution Scheduler v2.52 appeared first on How to Code .NET.
View ArticleNamed parameters with .net style method calls?
Hey guys, I know you can use named parameters when calling a powershell cmdlet, I’m curious about those times when you’re calling an actual method. For example. $myModule = Import-Module...
View ArticlePowerShell Multiple If Statements Help
How can I make my script run through each step and if it finds version of the app installed, execute the uninstall process and if it doesn’t continue the script, thank you in advance. ## Uninstall...
View ArticleRename-computer force restart with prompts
Sorry if this is ridiculously easy as I have little experience with PowerShell. I’m trying to create a script that will allow me to rename a computer and force a restart but I keep running into an...
View ArticlePowershell writes date to excel in wrong format
Hi All, I have a script I use on and off and have done for some time. The script is responsible for taking information from a user and filling in an excel form and generating an email. I have noticed...
View ArticleStatus of Windows Updates without WSUS
So, recently tasked with a project to make a report of Installed updates/hotfixes on systems in our environment that will report results to a SQL server for analysis daily. The wall that I am hitting...
View ArticleTrying to Learn Powershell Scripts
Hi All, I am currently creating myself a Powershell Script to Learn for work as well as make takes easier to complete. The issue I currently Have is I am unable to call a Submenu, would it be possible...
View ArticleHelp with an array object that is… weird?
I have a script that pulls all the dns records, filters out a few record types, and than pings the rest. $dnsrecords = Get-DnsServerResourceRecord -ZoneName $zonename -CimSession $session each record...
View ArticleTrouble With Invoke-Expression
I am trying to pass Invoke-Expression but it wont let me put a @ symbol in the command argument. Example: $command = "CMD.exe /c sqlplus.exe / as sysdba @$FileLocation" Invoke-Expression -Command...
View ArticleNeed help with non working function
This function needs uses the Get-ScriptConfig Module function Get-Wallpaper { [CmdletBinding()] param( [Parameter(Mandatory = $True, ValueFromPipeline = $True)] [System.URI]$url ) BEGIN{ #Reads Config...
View ArticleAD Shared Server path change
Hey guys, first time posting here. So I work in a pharmaceutical company and we have a x: drive setup for users to keep files for themselves, made in AD under profile and the drop down menu. The...
View Article