Quantcast
Channel: Active questions tagged powershell-3.0 - Stack Overflow
Browsing all 134 articles
Browse latest View live
↧

How do I write a value to an OPC tag in kepware using PowerShell

How do I write/update the value of tag2 in Kepware using PowerShell. This is my code example and I am getting the errorInvoke-RestMethod : The remote server returned an error: (400) Bad Request.At...

View Article


Is there a way to check if the script is running by PowerShell ISE?

I want to skip the Start-Transcript and Stop-Transcript lines if the PowerShell script is running by PowerShell ISE.Is this possible? And how can I achieve this?

View Article


Image may be NSFW.
Clik here to view.

API returning response as 3 instead of json when we copy request from "copy...

when i tried to copy request objects from chrome browser by "Copy as PowerShell" option , and try to paste that into PowerShell in my machine.i am getting content in response as 3 ,instead of json...

View Article

Enter-Pssession not working

I have to machines in same network one with windows7 and another win windows server 2012.I tried Enter-PSsession on windows7 machine from server2012 machine... $ComputerName = "windows7-PC"...

View Article

Replace-Files Powershell

I'm having some struggles with my PowerShell script. I am trying to make an Automated Script that will Perform the Utilman.exe Hack. The script has menus and options: Load, Unload, List Disk and Create...

View Article


How to remove property header from output when runnign Get-ADComputer

I want to pull the names of computer objects in AD in to a file. The method I'm trying so far is this$computers = Get-ADComputer -Filter * | Format-List namewrite($computers) | Out-File -FilePath...

View Article

How to properly export XML to file using Powershell

Importing any valid XML file as source using [XML]$Var = Get-Content -Path $PathToAnyValidXML I am unable to export it's content properly. Using Set-Content SomePath $Var , the file ends with...

View Article

Easier way to parse 'query user' in PowerShell (or quser)

I currently have the following query in PowerShell:query user /server:$serverWhich returns output:USERNAME SESSIONNAME ID STATE IDLE TIME LOGON TIME svc_chthost 2 Disc 1:05 8/16/2016 12:01 PM...

View Article


Suppressing VERBOSE for Import-Module

I'm importing Carbon into my PowerShell script; however when running my script with -Verbose, Carbon also outputs a lot of VERBOSE statements.Is it possible to Import-Module silently such that I can...

View Article


Setup default date format like yyyy-mm-dd in Powershell?

A simple & short question:How can I setup a default date format in powershell like yyyy-mm-dd ? so any date output will be like this format?or How to setup a date format globally in one script ?Is...

View Article

exporting from powershell to txt file

I'm trying to set up a scope on dhcp via powershell and export info to txt file. My code does what it needs to do, but when i export to txtfile with | out file it only exports the reserved ip not the...

View Article

How to truly automate a powershell script without scheduler

My script basically runs on specific times during a day. Accesses the server and downloads data. So far I have tried playing around with start-sleep command and timespan command but I am new to...

View Article

PowerShell 3: Every Command Execution Results In "The type initializer [...]...

DescriptionI've installed the new PowerShell version on my system a few months ago. Since that, something strange happens every time I use the shell. It doesn't trouble the functionality, but it's...

View Article


Powershell: Scheduled Task with Daily Trigger and Repetition Interval

I cant seem to figure out how to create a new scheduled task that is triggered daily and repeats every 30 minutes. I have been going in circles.Everything about this below works for setting the task I...

View Article
Browsing all 134 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>