Quantcast
Browsing all 21975 articles
Browse latest View live

get all files having last write time today

Hi, I want to get files only having last_write_time equal to today. The command i am trying: Get-ChildItem $source | where-object {$_.LastWriteTime -ge (Get-Date).adddays(-1)} Problem is, it's bringing...

View Article


Return list of values from invoke-command

Hi,I'm building a script to create IIS related stuff in my 4 web servers (they have no communication between them, so when I have to create a website, I have to create it 4 times!).I've started to...

View Article


Image may be NSFW.
Clik here to view.

Get-Recipient or Get-Mailbox and "white spaces" after import user to TXT files.

Hi Guys, In this week I had small task to move mailboxes from old SBS to new Exchange user. I have done this task with small problems. I decided of course to use Powershell to make my life simple.Step...

View Article

LineNumber not reporting correctly

Hi EveryoneI've been working on a side project of mine that helps me learn powershell and incorporate other languages, and I've hit a bit of a roadblock.My powershell script basically reads the latest...

View Article

Script open IE, press “okay” on cert selection, “open” file, close IE window

Im trying to create a script to Open an internet explorer window to a link, which i've worked out. But then i need it to click "OKAY" when a windows security certificate pops up, then click "open" when...

View Article


Telnet using powershell

I have list of servers, which should telnet to an ip address to port 12232, and display the result as Yes, IF the server can telnet to IP address, or NO, when it fails.How do I write a script in...

View Article

Split a specific property from the output of get-aduser

We have a field in AD that was generated for usage by a login script.  I am trying to extract a portion of that field for another use, and can not figure out how to process the data and add it to the...

View Article

Search a PDF and return specific text

I need to be able to search a PDF for about 200 different reference numbers that I know to return a value I do not know. Examples of the reference numbers:ABC-12-012ABC-012-86ABC-0512-10Where the...

View Article


PowerShell - Searching Excel and replacing text

Hi all,I am trying to figure out how to loop this script so that it replaces all the text that I am searching for in my Excel file.  I am able to get it to run but it only replaces the text in the...

View Article


automate 'Start Performance Counters'

I am able to automate the installation of PowerShell 3 on Windows 2008 R2 server and enabling remote administration so I can manage servers in the new Windows 8 Server Manager.  But the servers show up...

View Article

Remove entire O365 tenant - completely start new

Due to multiple changes to our O365 tenant through custom PS CMDlet scripts we have written we are now in a state of non-usable tenant. This is/was our POC to pre-stage our environment for our O365...

View Article

Remove entire O365 tenant - completely start new

Due to multiple changes to our O365 tenant through custom PS CMDlet scripts we have written we are now in a state of non-usable tenant. This is/was our POC to pre-stage our environment for our O365...

View Article

How can I format-table with two different variables

I have a script who's purpose is to go through all the mailboxes in exchange and look for any with SG_ or Group listed in the Full Access Permissions.  The script works though I'm having trouble...

View Article


Remote Removal Of Windows Shares

Hi,I am trying to automate a migration process involving thousands of user shares. In the past they were all entered as \\server\username$ & I am trying to move to DFS with just a few shares per...

View Article

Exchange - Contacts and Mailbox permissions

Hi,I need to setup forwarding for multiple users to a contact of the same name. (contacts are created)At the same time I would like to remove "self" permission and add the users account from a trusted...

View Article


select objects displayed in results

I have designed a form using PrimalForms which lets administrators search for AD user accounts, including deleted ones, they can also restore deleted accounts. The form allows you to search using 5...

View Article

Powershell Hyperv Inventory

Hello , I have around 10 HyperV standalone host , looking for a script that can take the HyperV host name as an input via text file and give following output as an csv file.1. Vm Name2. HyperV host...

View Article


Write-Progress

Trying to understand the Write-Progress cmdlet. From my understanding, it is to give an indicatin of how long the script will run, but in reality that is not the case. For instance from the following...

View Article

Gain Skills in PowerSkills

I have a question. In order to gain PowerShell skills and its scripting ability is it enough by reading books or do you need to have access to a large collection of servers, or many databases on the...

View Article

Target a specific domain controller when running a cmdlet

Nearly every cmdlet I'm using in a script supports -DomainController. Except one. Is there a way to force a cmdlet to use a specific DC? In this instance, remote PowerShell is not an option. This is a...

View Article
Browsing all 21975 articles
Browse latest View live