page contents My title page contents A Blog on Tools, Techniques and Announcements: PowerShell-Day7

Thursday, August 25, 2016

PowerShell-Day7


Understanding the GM,
When you run the command Get-Service,  you get the results as mentioned below
image
you can see the only three columns displayed are Status, Name and DisplayName,
Now this is because Microsoft has configured some configuration files which tells the command only to display certain columns, this could be cause certain commands have a lot of data
that can be displayed and will fill the entire screen with the  output.
There other Columns that are hidden for the service, Eg : Dependent service, Logon  Name, Etc.
if you want to see those columns then you need you need to know their property names
this is only possible using the Get-Member Command
image

Method : A way of telling an object of doing something /Actions, Eg : telling a service to Stop/Start
Event  : Fire off when something happens with service
Property : Columns available with the commands
TypeName : ServiceController,
Every different object will have a different Type Name associate with it, So the get-Service produces objects related to service Controllers.

No comments:

Post a Comment