Re: [powershell] Scripting registry queries

2015-03-20 Thread Kurt Buff
m] > On Behalf Of Kurt Buff > Sent: Friday, March 20, 2015 4:11 PM > To: powershell@lists.myitforum.com > Subject: Re: [powershell] Scripting registry queries > > Matt, > > I took this, and formatted it so that the statements that begin with foreach > are a single line - go

RE: [powershell] Scripting registry queries

2015-03-20 Thread Kelley, Matthew
: powershell@lists.myitforum.com Subject: Re: [powershell] Scripting registry queries Matt, I took this, and formatted it so that the statements that begin with foreach are a single line - got rid of the backticks. It worked like a champ. That's really nice - thank you very much. Kurt On Fri

Re: [powershell] Scripting registry queries

2015-03-20 Thread Kurt Buff
; + ` > > $(($wmi.GetExpandedStringValue(2147483650,"Software\Wow6432node\Microsoft\Windows\CurrentVersion\RunOnce",$name)).sValue) > ` > | Out-File c:\temp\RegValues.csv -Append} > > } > > > -Original Message- > From: listsad...@lists.myitforum.co

RE: [powershell] Scripting registry queries

2015-03-20 Thread Kelley, Matthew
: Friday, March 20, 2015 3:52 PM To: 'powershell@lists.myitforum.com' Subject: RE: [powershell] Scripting registry queries This works too: $Computers = get-adcomputer -filter { name -like "us-it*" } | select Name #put column names on csv file Out-File c:\windows\temp\RegVal

RE: [powershell] Scripting registry queries

2015-03-20 Thread Kelley, Matthew
tsad...@lists.myitforum.com [mailto:listsad...@lists.myitforum.com] On Behalf Of Kelley, Matthew Sent: Friday, March 20, 2015 3:48 PM To: 'powershell@lists.myitforum.com' Subject: RE: [powershell] Scripting registry queries No, that didn't work. Here, I put in some line breaks and this work

RE: [powershell] Scripting registry queries

2015-03-20 Thread Kelley, Matthew
e c:\temp\RegValues.csv -Append} } -Original Message- From: listsad...@lists.myitforum.com [mailto:listsad...@lists.myitforum.com] On Behalf Of Kelley, Matthew Sent: Friday, March 20, 2015 3:39 PM To: 'powershell@lists.myitforum.com' Subject: RE: [powershell] Scripting registry

RE: [powershell] Scripting registry queries

2015-03-20 Thread Kelley, Matthew
} -Original Message- From: listsad...@lists.myitforum.com [mailto:listsad...@lists.myitforum.com] On Behalf Of Kurt Buff Sent: Friday, March 20, 2015 3:32 PM To: powershell@lists.myitforum.com Subject: Re: [powershell] Scripting registry queries Matt, The only output I get from your scri

Re: [powershell] Scripting registry queries

2015-03-20 Thread Kurt Buff
e) > | Out-File c:\windows\temp\RegValues.csv -Append} > } > > When you open the csv with excel you will have to use the text to columns > tool on the ribbon... > > I also changed the output path to windows\temp - just for testing on my > machine. Works decent. Good luck

Re: [powershell] Scripting registry queries

2015-03-20 Thread Kurt Buff
ou know all your systems are online all the time... > > -Original Message- > From: Kelley, Matthew > Sent: Friday, March 20, 2015 12:53 PM > To: powershell@lists.myitforum.com > Subject: RE: [powershell] Scripting registry queries > > I understand. Give this a shot: &

RE: [powershell] Scripting registry queries

2015-03-20 Thread Kelley, Matthew
e csv with excel you will have to use the text to columns tool on the ribbon... I also changed the output path to windows\temp - just for testing on my machine. Works decent. Good luck! Matt -Original Message- From: listsad...@lists.myitforum.com [mailto:listsad...@lists.myitforum.com]

RE: [powershell] Scripting registry queries

2015-03-20 Thread Kelley, Matthew
o use the text to columns tool on the ribbon... I also changed the output path to windows\temp - just for testing on my machine. Works decent. Good luck! Matt -Original Message- From: listsad...@lists.myitforum.com [mailto:listsad...@lists.myitforum.com] On Behalf Of Kurt Buff Sent:

Re: [powershell] Scripting registry queries

2015-03-20 Thread Kurt Buff
On Fri, Mar 20, 2015 at 1:40 AM, Emin wrote: > Hi, > > I've got something similar at work for years now. > > You should split this into 2 main parts: > 1. the script that will run on clients and that will query the registry > 2. the script "engine" that will open sessions on remote computers with

Re: [powershell] Scripting registry queries

2015-03-20 Thread Kurt Buff
Responses in-line... On Fri, Mar 20, 2015 at 5:37 AM, Kelley, Matthew wrote: > Is this a one-time data capture, or something you need to do on a recurring > basis? Recurring, minimum once a week. > Do you have any systems management software, like SCCM, in your > environment? We have no system

RE: [powershell] Scripting registry queries

2015-03-20 Thread Kelley, Matthew
...@lists.myitforum.com [mailto:listsad...@lists.myitforum.com] On Behalf Of Emin Sent: Friday, March 20, 2015 4:41 AM To: powershell@lists.myitforum.com Subject: Re: [powershell] Scripting registry queries Hi, I've got something similar at work for years now. You should split this into 2 main parts: 1

Re: [powershell] Scripting registry queries

2015-03-20 Thread Emin
Hi, I've got something similar at work for years now. You should split this into 2 main parts: 1. the script that will run on clients and that will query the registry 2. the script "engine" that will open sessions on remote computers with a foreach loop and do for each target computer: Invoke-com