3

I want to update the counter value in command prompt in place.

E.g if you time "Timeout" in windows command prompt you can see how it decrements counter in place. Waiting for X seconds //where X keeps decrementing in place in Console.

I want to achieve the same from C#. Any idea how that can be done. Search doesn't seem to give any clues.

Frank Q.
  • 6,001
  • 11
  • 47
  • 62

1 Answers1

5

Use standard Console.Write but using Console.SetCursorPosition to set the position. Use this as clear example.

Community
  • 1
  • 1
Erre Efe
  • 15,387
  • 10
  • 45
  • 77