Examples of using Get-date in English and their translations into German
{-}
-
Colloquial
-
Official
-
Ecclesiastic
-
Medicine
-
Financial
-
Ecclesiastic
-
Political
-
Computer
-
Programming
-
Official/political
-
Political
The command that gets the system date is Get-Date.
The first command run the Get-Date cmdlet that comes with Windows PowerShell.
It does not affect the DateTime object that Get-Date retrieves.
Log-Value(get-date)-passthru This command adds the date to the end of the File1. log and File2.
Enter a DateTime object, such as one created by the Get-Date cmdlet.
Because functions take precedence over cmdlets, the Get-Date function from the TestModule module ran, instead of the Get-Date cmdlet.
To specify an alternate format,use the Format or UFormat parameters of Get-Date.
It uses the InputObject parameter to submit the results of a Get-Date command to the ConvertTo-Html cmdlet.
You can use Get-Date to generate a date or time character string, and then send the string to other cmdlets or programs.
When you use the Format or UFormat parameters, Get-Date generates a string, not a DateTime object.
The first command uses the PSSnapin property of theCmdletInfo object to find the snap-in that added the Get-Date cmdlet.
C:\PS> get-date-DisplayHint date Tuesday, June 13, 2006 Description This command retrieves a DateTime object, but it displays only the date.
This example uses Wait-Job to determine whether a Get-Date command running as a background job on three different computers is complete.
C:\PS> get-date-format g 6/13/2006 12:43 PM Description This command retrieves the current date and time and formats it in short-date and short-time format.
The expression gets the StartTime property of each process object andsubtracts it from the result of a Get-Date command, which gets the current date and time.
These commands demonstrate how to use Get-Date with Add-Content and other cmdlets that convert the DateTime object that Get-Date generates to a string.
Type a quoted string, such as"This data is for internal use only", or specify an object that contains content,such as the DateTime object that Get-Date generates.
C:\PS>$t get-date C:\PS> set-date-date$t These commands change the system date and time on the computer to the date and time saved in the variable$t.
This command gets a DateTime object and displays the current date and time in the long date and long time formats for the system locale,as though you typed"get-date-format F.