Quantcast
Channel: Windows PowerShell Forum
Browsing all 2562 articles
Browse latest View live

Microsoft Active Directory Modul: Where is the Documentation of the...

Hi everybody! If i Use the Microsoft Active Directory Modul with Get-ADComputer i get an Microsoft.ActiveDirectory.Management.ADComputer Object back. So where can i find the documentation for the...

View Article


Image may be NSFW.
Clik here to view.

PowerShell number of CPU sockets WMI query?

Any one has an idea how to accomplish this? I am trying with the query attached but the properties are reporting null for some reason although the variable itself shows some data. I am interested in...

View Article


Problem specifying a default value when using parameter sets in powershell

I'm currently in the process of writing a script that takes advantage of Powershells comment-based help and plan on using Get-Help from within the script itself. This will allow me to have a -Help...

View Article

Image may be NSFW.
Clik here to view.

Module level abstraction\Scope?

I am trying to hide an internal function in the module from the end user.  Is there any way to do this? #spike.psm1 file function get-a{   a } function script:a {     'This is a' } Export-ModuleMember...

View Article

PS Invoke-SqlCmd output to file is empty

I'm trying to run a script using the following: invoke-sqlcmd -serverinstance PC01 -database DEV -inputfile "D:\BuildDatabase.sql" -verbose | out-file -filepath "D:\SqlLog.txt" The script generates an...

View Article


Image may be NSFW.
Clik here to view.

Problem setting registry permissions using Powershell

I have a couple of scripts that I have put together to change the registry value of a specific key in the registry.  This primarily is being done on our Windows 7 machines as the XP setup is slightly...

View Article

Regular Expression - Question regarding pattern matching

Hello together, I got the following string: <?xml version="1.0" encoding="UTF-8"?> <user> <user ritaID="METADIR"> <item desc="RASL Std. GPNR" name="testibus" value="562532525"/>...

View Article

Make multiple selection on a list to do another task

Hey guys, Currently I got two script here. One is List out all the services and the other one is to start or stop the services. In order to start or stop the services, currently I need to list out all...

View Article


Working with files, who's paths are too long

Is there any way of getting around the dreaded error Get-ChildItem : The specified path, file name, or both are too long. The fully qualified file name must be less than 260 characters, and the...

View Article


find users NOT in group

hello, i need to find all users in AD that are not meber in one of the group named "Permanent sometring"; i tryed the next command: Get-ADUser -Filter * -properties memberof | Where-Object {$_.memberof...

View Article

How do you remove a list of users from an OU with Powershell?

A single OU was created and several groups were created within. These groups are used to give users permissions within a program. The program was searched for inactive users and there are over 800. So...

View Article

using something else in place for "-file"

Hello, I have been using the latest version of Powershell 3.0 and all of my scripts work fine for what I am trying to do. I have recently been informed that I should design my scripts to work on other...

View Article

Automatic/Scripted Account Creation Using an X.500 Feed

I am posting this question in a few different forums on here just to make sure my bases are all covered. Here's my problems: I have a client with 2 separate entities; a corporate entity and an R&D...

View Article


Using an LDAP attribute to put users into AD Groups

Via this thread: http://social.technet.microsoft.com/Forums/en-US/winserverDS/thread/ea39e821-50ba-494e-b608-df879a0e28ca And this blog post:...

View Article

get-aduser group membership

Hi, I want to use the get-aduser cmdlet to return all nested groups that a user belongs to.  I've tried : (GET-ADUSER –Identity User1 –Properties MemberOf | Select-Object MemberOf).MemberOf However...

View Article


powershell upgrade

I am run VMware on a windows 7 OS,  the VM is Windows 2008 R2.  trying to upgrade Powershell V.1 to V.2.  I am getting the follow error "the update is not applicable to your computer"  Need HELP!!!...

View Article

new object with the properties of another object

I’m trying to make a new object that has all the properties of three other objects. I’d like the new object’s property names to be prefaced by the other objects name. For example, If I have the object...

View Article


Send email to buld user via powershell

How would  i send email to bulk user as individual $getaddress = Import-csv c:\emailaddress Send-mailmessage -To "$getaddress" -from test8521@Mytechnet.me -subject "Update your profile)" -BodyAsHtml...

View Article

Powershell v3 Invoke-WebRequest HTTPS error

Using Powershell v3's Invoke-WebRequest and Invoke-RestMethod I have succesfully used the POST method to post a json file to a https website. The command I'm using is...

View Article

Color Property, PivotSelect in Excel

I am trying to set the color of the pivottables subtotals. I can accomplish this pretty easy in VBA with this activesheet.PivotTables(1).PivotSelect("Description[All;Total]",0) selection.Interior.Color...

View Article
Browsing all 2562 articles
Browse latest View live


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