Quantcast
Channel: Windows PowerShell forum
Browsing all 21975 articles
Browse latest View live

Cluster Aware Updating -Test-CauSetup -Hostname Failing -FQDN Working

I have been searching blog after blog and trying everything I have seen but I cannot seem to get "Cluster Aware Updating" past the below error. I tried posting in the Hyper-V forum but I was told I...

View Article


How to filter the Microsoft.PowerShell.Commands.GroupInfo object?

Dear professionals,This PowerShell script for counting by file extension as follows works good.get-childitem "C:\Windows\System32" | Group Extension | Select Name,...

View Article


KQL parser threw an exception.

Get-mailbox Myuser@xyz.com | Search-Mailbox -SearchQuery 'Subject:"$subject" AND From:"$sender" AND Received:"$Receivedate"' -TargetMailbox "$TargetmailboxEmail" -Targetfolder "$Foldername" -LogLevel...

View Article

Does Compare-Object return anything if there is an exact match?

I am doing some validation on a file/folder copy and want to use Compare-Object to validate the copy.  Using the script listed below I see no result from my Compare-Object.  Am I missing something?...

View Article

Invoke-command Get-Childitem \\share UnauthorizedAccessException

Hello,I've trouble with accessing a remote share from an invoke-command like this :Invoke-Command  -ComputerName $srv -ScriptBlock {Get-Childitem \\share -recurse -filter "*" }where as  :Invoke-Command...

View Article


Set AD Extension attribute

Hi,I have created a script that successfully adds a value to to extension attribute 7 to users from a CSV file. But I want the user that executes the script to be able to manually specify a value...

View Article

How to make a text box as transparent using powershell

How to make a text box as transparent using <g class="gr_ gr_4 gr-alert gr_spell gr_inline_cards gr_run_anim ContextualSpelling ins-del multiReplace" data-gr-id="4" id="4">powershell</g>...

View Article

Script problems when trying to embed mac address variable in foreach-object...

Dear Script Specialist's ,I have a power shell script to create and update an entry on computer registry . the script simply gets the mac address of the PC and then compares it in an inventory file ....

View Article


Powershell command access

Hello,I am trying to get the certificate for SCCMGet-ChildItem Cert: | ? {$_.Extensions | ? {$_.oid.friendlyname -match "Template" -and $_.Format(0) -match "SCCM"}}I ran the command on Windows 10 &...

View Article


Get stopped service from system excluding Delayed and triggered services

Trying below command to get the stopped service list without delayed and triggered.. I excluded the delayed service but triggered comes in output if it is in stopped state Invoke-Command -ScriptBlock {...

View Article

LastAccessTime - Querying Folder Properties Resets TimeStamp

I have enabled the LastAccessTime attribute on a handful of old servers in hopes to start detecting folders/file that are not being used. This works as it should.I am trying to select the...

View Article

Image may be NSFW.
Clik here to view.

PowerShell script to put Citrix XenDesktop VDI in maintenance mode when...

 Objective: A PowerShell Script to find all AD inactive/disabled user accounts, then put their corresponding Citrix XenDesktop VDI in maintenance mode if exist.I got the below code but not sure how to...

View Article

Extracting Username and Machine Name data from AD thru PowerShell

I am sure a relatively simple script can extract both username and computer machine name data from AD for my company.To date, I've written two simple PS scripts each of which retrieves these two...

View Article


How to export group names to CSV when using get-aduser?

I am trying to get information regarding AD users including which group they are a member of. I can get the list of users and thier information easily but the groups is a headache for me. I have tried...

View Article

Active Directory Nested Group Report

I have this powershell script that I created for reporting on SamAccountName and all the groups and nested groups each user belongs to. Now I need to get more information about each user account....

View Article


Command line with a pipe symbol

I'm trying to run the following command in Powershellcmd /c net use | find "K:"It's failing with FIND: Parameter format not correcI've tried everything like invoke-expression but it doesn't work!I've...

View Article

Where maximum not in

I have a Powershell script where I take the maximum value from the column of an Excel sheet and assign it to a variable. $dt_str = ($dt|Measure-Object -Property "Part_No" -max).Maximum It works but I...

View Article


How to Output Entire Content of JSON Nested Hash Table in PoweShell

How can I output the entire contents of a nested JSON hash table to a PS object in one line?$json = @" {"outer": "value1","outerArray": ["value2","value3" ],"outerHash": {"inner":...

View Article

Convert text file to html

I have a text file with 100 lines. I want to convert it to html. However when I do that the html file does not come line by line butmultiple lines are appearing on the same line. How can I resolve...

View Article

How to call sconfig utility from powershell script and passing input

Hi I want to call sconfig utility from powershell script and passing input. Can somebody please advise how to do it? For instance I want to run sconfig and choose 5 option. Then I want to choose M. How...

View Article
Browsing all 21975 articles
Browse latest View live


Latest Images

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