In the previous tip, we illustrated how you can use Registry information to find wireless network adapters. Here is now a function...
posts-powershell
Categories
- Free tools
- SQL Admin Toolset
- SQL Compliance Manager
- SQL Defrag Manager
- SQL Diagnostic Manager for MySQL
- SQL Diagnostic Manager for SQL Server
- SQL Diagnostic Manager Pro
- SQL Doctor
- SQL Enterprise Job Manager
- SQL Inventory Manager
- SQL Query Tuner for SQL Server
- SQL Safe Backup
- SQL Secure
- SQL Workload Analysis for SQL Server
- Uptime Infrastructure Monitor Formerly Uptime
Tags
Administration agent-based monitoring Agentless Monitoring alert responses alert thresholds alerting Alerts Amazon Aurora Amazon EC2 Amazon RDS Amazon RDS / Aurora Amazon RDS for SQL Server Amazon Redshift Amazon S3 Amazon Web Services (AWS) Analytics application monitoring Aqua Data Studio automation availability Azure Azure SQL Database azure sql managed instance Azure VM backup Backup and recovery backup and restore backup compression backup status Backup Strategy backups big data Blocking bug fixes business architecture business data objects business intelligence business process modeling business process models capacity planning change management cloud cloud database cloud database monitoring cloud infrastructure cloud migration cloud providers Cloud Readiness Cloud Services cloud storage cloud virtual machine cloud VM clusters code completion collaboration compliance compliance audit compliance audits compliance manager compliance reporting conference configuration connect to database cpu Cross Platform custom counters Custom Views customer survey customer testimonials Dark Theme dashboards data analysis Data Analytics data architect data architecture data breaches Data Collector data governance data lakes data lineage data management data model data modeler data modeling data models data privacy data protection data security data security measures data sources data visualization data warehouse database database administration database administrator database automation database backup database backups database capacity database changes database community database connection database design database developer database developers database development database diversity Database Engine Tuning Advisor database fragmentation database GUI database IDE database indexes database inventory management database locks database management database migration database monitoring database navigation database optimization database performance Database Permissions database platforms database profiling database queries database recovery database replication database restore database schema database security database support database synchronization database tools database transactions database tuning database-as-a-service databases DB Change Manager DB Optimizer DB PowerStudio DB2 DBA DBaaS DBArtisan dBase DBMS DDL Debugging defragmentation Demo diagnostic manager diagnostics dimensional modeling disaster recovery Download drills embedded database Encryption End-user Experience entity-relationship model ER/Studio ER/Studio Data Architect ER/Studio Enterprise Team Edition events execution plans free tools galera cluster GDPR Getting Started Git GitHub Google Cloud Hadoop Healthcare high availability HIPAA Hive hybrid clouds Hyper-V IDERA IDERA ACE Index Analyzer index optimization infrastructure as a service (IaaS) infrastructure monitoring installation Integrated Development Environment interbase Inventory Manager IT infrastructure Java JD Edwards JSON licensing load test load testing logical data model macOS macros managed cloud database managed cloud databases MariaDB memory memorystorage memoryusage metadata metric baselines metric thresholds Microsoft Azure Microsoft Azure SQL Database Microsoft PowerShell Microsoft SQL Server Microsoft Windows MongoDB monitoring Monitoring Tools Monyog multiple platforms MySQL news newsletter NoSQL Notifications odbc optimization Oracle PeopleSoft performance Performance Dashboards performance metrics performance monitoring performance schema performance tuning personally identifiable information physical data model Platform platform as a service (PaaS) PostgreSQL Precise Precise for Databases Precise for Oracle Precise for SQL Server Precise Management Database (PMDB) product updates Project Migration public clouds Query Analyzer query builder query monitor query optimization query performance Query Store query tool query tuning query-level waits Rapid SQL rdbms real time monitoring Real User Monitoring recovery regulations relational databases Releases Reporting Reports repository Restore reverse engineering Roadmap sample SAP Scalability Security Policy Security Practices server monitoring Server performance server-level waits Service Level Agreement SkySQL slow query SNMP snowflake source control SQL SQL Admin Toolset SQL CM SQL code SQL coding SQL Compliance Manager SQL Defrag Manager sql development SQL Diagnostic Manager SQL Diagnostic Manager for MySQL SQL Diagnostic Manager for SQL Server SQL Diagnostic Manager Pro SQL DM SQL Doctor SQL Enterprise Job Manager SQl IM SQL Inventory Manager SQL Management Suite SQL Monitoring SQL Performance SQL Quality SQL query SQL Query Tuner SQL Safe Backup SQL script SQL Secure SQL Security Suite SQL Server sql server alert SQL Server Migration SQL Server Performance SQL Server Recommendations SQL Server Security SQL statement history SQL tuning SQL Virtual Database sqlmemory sqlserver SQLyog Storage Storage Performance structured data Subversion Support tempdb tempdb data temporal data Tips and Tricks troubleshooting universal data models universal mapping unstructured data Uptime Infrastructure Monitor user experience user permissions Virtual Machine (VM) web services webinar What-if analysis WindowsPowerShellFinding Wireless Network Adapters
There are many ways of finding network adapters, but apparently none to identify active wireless adapters. All information about your network...
Drive Data in GB and Percent
When a cmdlet returns raw data, you may want to convert the data into a better format. For example, WMI can report the free space of a drive but...
Finding Hard Drives Running Low on Storage
WMI can retrieve information about drives easily. This will get you the drive information for your local machine (use -ComputerName to access a...
Finding Errors since Yesterday
Relative dates are important to get data within a special time frame, avoiding hard-coded dates and times. This script will get all error and...
Exporting Data to Excel
You can easily convert object results to CSV files in PowerShell. This generates a CSV report of current processes: To open the CSV file in...
Finding Events around A Date
Often, you might want to browse all system events around a given date. Let's say a machine crashed at 08:47, and you'd like to see all...
Auto-Connecting with Public Hotspot
Many mobile phone service providers offer public hotspots at airports and public places. To connect, you typically need to browse to a logon page,...
Padding Strings Left and Right
If you must make sure that a given string has a uniform width, then you can use .NET methods to pad the string appropriately: $mytext =...
Formatting Numbers Easily
Often, users need to format numbers and limit the number of digits, or add leading zeros. There is one simple and uniform strategy for this: the...
Eliminating Duplicates
Sort-Object has an awesome feature: with the parameter -Unique, you can remove duplicates: This can be applied to object results, as well. Check out...
Beware Of Hidden Password Requests
You can run PowerShell code in any host, and Windows ships with powershell.exe and powershell_ise.exe. Many prefer the graphical ISE editor over the...
Tag Your Objects with Additional Information
There may be the need to add additional information to command results. Maybe you get data from different machines and want to keep a reference...
Save Time With Select-Object -First!
Select-Object has a parameter called -First that accepts a number. It will then return only the first x elements. Sounds simple, and it is. This...
Expanding Variables in Strings
To insert a variable into a string, you probably know that you can use double quotes like this: $domain = $env:USERDOMAIN $username = $env:USERNAME...
Using Aliases to Launch Windows Components
PowerShell is not just an automation language but also an alternate user interface. If you do not like the graphical interface, educate PowerShell...
Filtering Text-Based Command Output
Comparison operators act like filters when applied to arrays. So any console command that outputs multiple text lines can be used with comparison...
Keeping a Handle to a Process
When you launch an EXE file, PowerShell will happily start it, then continue and not care about it anymore: If you'd like to keep a handle to...
Use $PSScriptRoot to Load Resources
Beginning in PowerShell 3.0, there is a new automatic variable available called $PSScriptRoot. This variable previously was only available within...
Signing VBScript Files with PowerShell
You probably know that Set-AuthenticodeSignature can be used to digitally sign PowerShell scripts. But did you know that this cmdlet can sign...
Correctly Filtering DateTime
When you use Where-Object to filter information by date or time, this works actually very well--provided you use the correct filtering format. Do...
Use Fresh Testing Environment in PowerShell ISE
When you develop PowerShell scripts in the PowerShell ISE editor, you should run the final tests in a clean environment, making sure that no...
Importing Multiple Certificates from PFX Files
Get-PfxCertificate can import digital certificates from a PFX file. However, it can only retrieve one certificate. So if your PFX file contains more...
Using Fully Qualified Names in Remoting
When you try PowerShell Remoting, you may run into connection errors just because your machine name was not fully qualified. Kerberos authentication...
Ensuring Backward Compatibility
Let's assume you have created this function: function Test-Function { param ( [Parameter(Mandatory=$true)] $ServerPath ) "You selected...
Importing Certificates from PFX Files
You can use Get-PfxCertificate to load digital certificates from PFX files, and then use the certificate to sign script files, for example: $pfxpath...
Reading StringExpand Registry Values
When you read a Registry value of type StringExpand, it will always automatically expand any environment variables contained in the text. This...
Setting (And Deleting) Environment Variables
PowerShell can read environment variables easily. This returns the current windows folder: $env:windir However, if you want to make permanent...
Mandatory Parameter with a Dialog
Typically, when you mark a function parameter as "mandatory", PowerShell will prompt the user when the user omits the parameter: function...
Using Comma as Decimal Delimiter
You may not be aware of this, but PowerShell uses a different decimal delimiter for input and output - which may cause confusions to script users....