0

I am trying to generate timestamp with the following format 2017-11-11T19:33:27.

With Get-Date -Format o I am able generate 2017-11-13T07:39:32.7958466-05:00

How can I remove milliseconds .7958466-05:00 in the generated output?

1
  • I edited your title and text as you talked about Get-Content instead of Get-Date Commented Nov 13, 2017 at 12:53

1 Answer 1

3

Use Get-Date -Format s instead of Get-Date -Format o

Formatting Dates and Times

Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.