Patrick_ Posted August 4, 2004 Share Posted August 4, 2004 How would I do a delay for a Console.Writeline? Meaning, I want to say something, and then say, "Please Wait", and then have it delay for X amount of seconds before the next response. How would i do it? Thank you! Link to comment Share on other sites More sharing options...
0 Delsphynx Posted August 4, 2004 Share Posted August 4, 2004 Import System.Threading Then look at the command: Thread.Sleep(milliseconds) Link to comment Share on other sites More sharing options...
0 Patrick_ Posted August 4, 2004 Author Share Posted August 4, 2004 Sweet, thanks. Now, how do I import System.Threading? It says it is a namespace, so not a valid expression.... Link to comment Share on other sites More sharing options...
0 John Veteran Posted August 4, 2004 Veteran Share Posted August 4, 2004 At the top of your code, you should see a few lines like "Imports System", add it there (Y) Link to comment Share on other sites More sharing options...
0 Patrick_ Posted August 4, 2004 Author Share Posted August 4, 2004 No, it's really weird, I don't. It's a command prompt application, and all I have at the top is: Module Module1 Sub Main() Sorry, it's my second day of programming, so... :) Link to comment Share on other sites More sharing options...
0 Delsphynx Posted August 4, 2004 Share Posted August 4, 2004 Put it in right above Module Module1 Link to comment Share on other sites More sharing options...
0 bwx Posted August 5, 2004 Share Posted August 5, 2004 There are examples for the most popular .NET languages (including VB) here: http://msdn.microsoft.com/library/default....ssleeptopic.asp Hope that helps. Link to comment Share on other sites More sharing options...
0 Mordkanin Posted August 5, 2004 Share Posted August 5, 2004 System.Theading.Thread.CurrentThread.Sleep(time in milliseconds) Link to comment Share on other sites More sharing options...
Question
Patrick_
How would I do a delay for a Console.Writeline?
Meaning, I want to say something, and then say, "Please Wait", and then have it delay for X amount of seconds before the next response. How would i do it?
Thank you!
Link to comment
Share on other sites
7 answers to this question
Recommended Posts