Quantcast
Channel: Hey, Scripting Guy! Blog
Viewing all articles
Browse latest Browse all 3333

PowerTip: Use PowerShell to Display Date Formats

$
0
0

Summary: Use Windows PowerShell to easily change the way the date displays on your computer.

Hey, Scripting Guy! Question How can I use Windows PowerShell to display the date on my computer as a two-digit month, two-digit day,
          and two-digit year?

Hey, Scripting Guy! Answer Use the ToString() method from the Get-Date cmdlet. Here are two examples:

PS C:\> (get-date).tostring("MM/dd/yy")

05/19/14

PS C:\> (get-date).tostring("MMddyy")

051914


Viewing all articles
Browse latest Browse all 3333

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>