PowerShell

Uninstall Software using PowerShell

  Hi, today i was trying to uninstall the the software using PowerShell. i See few blog posts about uninstalling software using PowerShell they re recommending WMI to uninstall software using the .Uninstalled() method. But i think this method is not right because it don’t un-installed the software properly. Sometime uninstalling software using these method… Continue reading Uninstall Software using PowerShell

PowerShell

How to use –Exclude switch in Remove-Item cmdlet in PowerShell

Hi, today i was trying to remove some junk folders and files in a  specific folder. But i don’t want to remove all of file and folder , i want to keep few folders. Then i think that i should use the –Exclude switch with Remove-Item Cmdlet. I tried to use –Exclude switch but somehow… Continue reading How to use –Exclude switch in Remove-Item cmdlet in PowerShell

PowerShell

Creating System Footprints using PowerShell

    WMI can retrieve a lot more object instances than you might think. If you submit a parent class, Get-WmiObject returns all instances of all derived classes. That’s why a simple line like the following can get you all hardware-related instances: PS> Get-WmiObject -Class CIM_PhysicalElement | Group-Object -Property __Class   Count Name                                                       Group… Continue reading Creating System Footprints using PowerShell

PowerShell

“More” Can Be Dangerous – Use Better Alternative in PowerShell

  PowerTip of the Day, from PowerShell.com:   You might know the more.com tool: when you pipe output to more.com, the output is displayed page by page: PS> Get-EventLog -LogName System | more However, “more” can be dangerous as you see here. You will not get any results for a long time, and your CPU… Continue reading “More” Can Be Dangerous – Use Better Alternative in PowerShell