Search found 13305 matches

by jvierra
Thu Oct 11, 2012 11:06 am
Forum: Windows PowerShell
Topic: How to see duplex settings on NIC
Replies: 3
Views: 912

How to see duplex settings on NIC

You cannot set that with WMI. It can usually only be done using the manufacturers utilites or with the DEVCON utility.
by jvierra
Sun Oct 07, 2012 3:27 pm
Forum: Windows PowerShell
Topic: querying a group via - System.DirectoryServices.AccountManagement.PrincipalSearcher
Replies: 3
Views: 1615

querying a group via - System.DirectoryServices.AccountManagement.PrincipalSearcher

Interseting but it is not clear how you came upwith that. Try using ADSI. Try using a query. ([adsisearcher]'cn=qbusers2').FindOne()$se.FindOne() No need to try and copy those highly advanced C# methods, They only work under very specific conditions. The ADSI searcher gets you there always and very ...
by jvierra
Thu Sep 27, 2012 6:49 am
Forum: VBScript
Topic: Search a string in a text file. If it does not exist add it to the file.
Replies: 3
Views: 4646

Search a string in a text file. If it does not exist add it to the file.

I am guessing at what you are trying to do.

If my guess is correct then this is all you need to do.

See attached file:

Attached files /FileUpload/98/bb9a84b0d97a7bed874a5cf4cd701f.txt (1.1 KB)
by jvierra
Thu Sep 27, 2012 6:14 am
Forum: VBScript
Topic: Search a string in a text file. If it does not exist add it to the file.
Replies: 3
Views: 4646

Search a string in a text file. If it does not exist add it to the file.

I am sorry but it is very difficult to understand what you are asking. If you are gettng an error message then please post it. You gave posted what looks like batch script an you are posting a vbscript also. What is it the you are trying to do? The code posted is hard to read and will not copy well....
by jvierra
Tue Sep 25, 2012 1:00 am
Forum: Windows PowerShell
Topic: And alternative to Posh v3 | out-grid -passthru in Posh v2
Replies: 2
Views: 583

And alternative to Posh v3 | out-grid -passthru in Posh v2

Yes - write your own grid form that works like Out-Gridview V3. With PowerShell Studio 2012 this is fairly easy.

Also search the Internet for updated versions of the CmdLet.
by jvierra
Mon Sep 24, 2012 5:56 am
Forum: Windows PowerShell
Topic: aligning import-csv -header when using | out-file
Replies: 2
Views: 742

aligning import-csv -header when using | out-file

You have to format the object for text output using Format-Table, Format-List, ConvertTo-Html, or build a hand formatter.

import-csv events.csv|Format-Table -auto|out-file testout.txt
by jvierra
Mon Sep 24, 2012 5:37 am
Forum: Windows PowerShell
Topic: parsing hpacu output
Replies: 12
Views: 2510

parsing hpacu output

The diagnostic version outputs a more user friendly version:

See the atached file.


Attached files /FileUpload/cb/fa133d886316be649c4e341377bae9.txt (1.9 KB)
by jvierra
Mon Sep 24, 2012 4:21 am
Forum: Windows PowerShell
Topic: Redirecting Default Out
Replies: 1
Views: 268

Redirecting Default Out

I answered this in the other thread already. YOu shouild probably delete this duplicate thread.
by jvierra
Sun Sep 23, 2012 1:28 pm
Forum: Other Scripting Languages
Topic: MS Access 2010
Replies: 2
Views: 26644

MS Access 2010

The PrimalScrip type for VB files will edit VBA but you will not have Office Intellisense. The Office VBA editor is more approproaite. PrimalScript is Excelent at building VBScript scripts that access Office products. Here ios an example of using VBScript to adcess Excel: sExcelFile = "f:testdest.xl...
by jvierra
Sun Sep 23, 2012 8:33 am
Forum: Windows PowerShell
Topic: changing out-default to a text file rather than the out-host
Replies: 2
Views: 688

changing out-default to a text file rather than the out-host

You can suppress output to the console by running the session as a script. You cannot supress output that is set to Out-Default to go to a file unless you redirect the whole script. Output sent from Write-Host and Write-Verbose or Write-Debug cannot be redirected in PowerShell V2 but can is Posh V3....