1. Using Out-Null Cmdlet : Hides/discards the output instead of sending it down the pipeline or displaying it.
2. Typecasting to [void] : This is more of a very C#-flavored trick
3. Redirection to $NULL: Redirecting the output to the Automatic variable $Null
4 . Assignment to $NULL: Assigning the output to the Automatic variable $Null… Read More 4 ways to send output to NULL in PowerShell
I often find myself in situations when I want to PSRemote multiple servers with server names in such a series that has same prefix server names and suffixed by a 2 digit number like- sameprefix05 sameprefix06 sameprefix07 sameprefix08 sameprefix09 sameprefix10 sameprefix11 sameprefix12 sameprefix13 sameprefix14 sameprefix15 and to avoid saving the server names in a file… Read More Powershell Tip: Adding leading zeros
My top preference for data munging and harvesting from The Web is Internet Explorer, Yes, Internet Explorer! 🙂 because I can create an InternetExplorer.Application object and access the HTML DOM to scrape web data as and when required. The problem arises when all information on the web page is not populated by default when the page loads,… Read More Scrolling Internet Explorer with Powershell
* Color-coded output depending upon the Value of the Datapoint; Above or below predefined thresholds
* Display custom information on X and Y-Axis labels
* A Graph in the console that is independent and fully customizable, not like Task Manager’s (no need to switch to Performance Tab) and,
* Could be easily used in any Powershell script to monitor performance on any defined parameter, which I see as the biggest benefit of the function.
* Function consumes data points, generated during script execution or Pre-stored data like from a file or database.… Read More Plot Graph in Powershell console
I came across some fun stuff on the internet, so I wrapped it inside a Powershell Function for this blog post. The idea is to get weather report in Powershell console using this cURL implementation converted into Powershell function below Just pass a name of the City as a parameter to the Function to get… Read More Get-Weather report using Powershell
Introduction: A couple of URL shortening services like Google and TinyURL are available over the Internet, and I’m a big fan as Short or Tiny URLs as they are very useful to share contents on social media (Eg. Twitter with 140 Char limit), especially for bloggers, but they can be used for malicious purposes by… Read More Expand Short URL using Powershell
Introduction: Yesterday while troubleshooting a network issue, I realized that if I can know the vendor of a MAC Address, then I could understand if it’s a Dell Router, a VMWare virtual NIC or a Dell server then maybe it will make life a bit easy, like in the following example. The Idea and Making it work:… Read More Get-MACVendor using Powershell