Quantcast
Channel: /r/powershell – How to Code .NET
Browsing all 8793 articles
Browse latest View live

Exporting and importing PowerShell credentials between different...

submitted by /u/bmsimons [link] [comments] The post Exporting and importing PowerShell credentials between different machines/user accounts appeared first on How to Code .NET.

View Article


Powershell Scripts in GPO

I’m trying to troubleshoot a startup script GPO. I think the reason my script isn’t working is because of the exection policy. Does anyone know if powershell machine startup scripts in GPO need to be...

View Article


Email attachment CSV with only specific colums

I’ve been tasked with running a weekly report that shows accounts expiring. I’ve been using this (https://blogs.technet.microsoft.com/makeiteasy/2012/11/23/auto-mail-expiring-domain-accounts/) pretty...

View Article

Search for subfolder beneath C:Users

Need some help. I want to search for a subfolder beneath C:Users. It will probably only exist in one location, but could possibly be in multiple locations. If the folder exists, I want to delete it....

View Article

Pulling what little hair I have out. HELP

.So here is the absolute breakdown.. wow this blows my mind, bear with me lol Here we show what’s in that directory for logs PS C:Users212590575Desktop> dir...

View Article


Can anyone tell me if this would be possible to script?

Thanks for taking interest first of all as I’m grateful for any suggestions I get. I work for a cloud hosting team, and we have a bunch of different servers hooked up to a single AD domain that users...

View Article

ConvertTo-HTML with 1 property

I have a table that only has one property and when I use ConvertTo-HTML I get an * in the title header. From what I’ve read this is a bug, does anyone know of a work around for this? submitted by...

View Article

Error Handling Question

I have a script that ssh into server and uses scp to transfer files and a few other things However I want to know when it comes up with errors Preferably by email. Is there anything that could do...

View Article


I can’t get this command to output to a file

foreach ($server in Get-ExchangeServer){Get-ReceiveConnector -identity ($server.ToString() + “Allow Relay External”) | select -ExpandProperty RemoteIPRanges | Out-file c:tempconnectors3.txt} I’ve...

View Article


Just learning, but does this sound like a reasonable approach?

I just jumped into PS scripting today, so please pardon my ignorance. I am a web developer/ PHP programmer, but I think I can do what I need using PS script, once I’ve learned enough to write the...

View Article

[script help] Storing the entire contents of a config file as a variable

Hey /r/Powershell! I’ve got a relatively simple sounding problem. I’m writing a script to download and install Firefox, then write out a series of config files to certain paths. The installer is...

View Article

how to run hyperv cmdlets without administrator?

PS C:> Get-VM Get-VM : You do not have the required permission to complete this task. Contact the administrator of the authorization policy for the computer At line:1 char:1 + Get-VM + ~~~~~~ +...

View Article

Something very interessting to look at.

submitted by /u/kevmuf [link] [comments] The post Something very interessting to look at. appeared first on How to Code .NET.

View Article


Need to know if a script is possible.

Hey Guys, novice scripter here with a rather long winded question that really does stretch my knowledge of powershell. Basically, a really, really lengthy process has been dropped on me that I’d...

View Article

Powershell pulling the wrong username into variable

I’m trying to deploy software via powershell script, but the script keeps using the username that runs the deployment. As i test, i opened powershell as administrator under a user account, and logged...

View Article


Question:Verifying Members Exists

I have a script that takes in a csv file created by project managers placed in a directory. recently i had some weird errors happening and investigating it turned out that one of the PMs had renamed...

View Article

I want to grab lines of data in some bat files and replace them, can you help...

$files = Get-ChildItem "K:Pathpath$file" -Filter *.bat | Select-object name foreach($file in $files) { (Get-Content "K:DFSITPDQ_DeployBatches$file") | ForEach-Object { $_ -replace "\path", "\newpath"...

View Article


Strange Issue ‘Getting’ IIS Application Pools

Hey everyone. So, I’ve encountered this issue before and after finding no decent solution, I simply found a way to work around it. Now it seems I may not have a choice but to ascertain what exactly is...

View Article

Help simple install

(Start-Process -FilePath “msiexec.exe” -ArgumentList “/i Program_01.msi Provider=SQLOLEDB001 ConnectionString=”Data Source=City005;Integrated Security=SSPI;Initial Catalog=Bisset” /qb!” -Wait...

View Article

Grabbing last user to have logged into a computer (inactive and active) in a...

I have been tasked with inventorying the computer accounts within a domain. I’ve done so fairly simply with google, however my google-fu has failed me on one area – I can get the last logged on user...

View Article
Browsing all 8793 articles
Browse latest View live


Latest Images