Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Help with text
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
KereD




PostPosted: Sun Nov 27, 2005 4:33 pm   Post subject: Help with text

What would be the coding i use if i want to ouput some text but only it be outputted if i hit 'Enter'

so for example
put "hi"
put "hello"
put "hey"

I would want that to be outputted only after hitting the enter key
Sponsor
Sponsor
Sponsor
sponsor
MysticVegeta




PostPosted: Sun Nov 27, 2005 4:41 pm   Post subject: (No subject)

Check Input.KeyDown in turing manual F10
Cervantes




PostPosted: Sun Nov 27, 2005 5:33 pm   Post subject: (No subject)

Or perhaps getch would be better. It would only output your text each time you hit enter, rather than each time the button is determined to be down.

Check the Turing Walkthrough for some links.
ZeroPaladn




PostPosted: Mon Nov 28, 2005 10:07 am   Post subject: (No subject)

or perhaps just an Input.Puase in between each put statement. Input.Pause waits for ANY keystroke beofre continuing.
DIIST




PostPosted: Tue Dec 06, 2005 9:26 pm   Post subject: (No subject)

Getch would be the best. Its really easy to use. Plus, with Input.Pause, it may echo the keys.
ZeroPaladn




PostPosted: Wed Dec 07, 2005 9:37 am   Post subject: (No subject)

then just set the screen...
code:
View.Set ("noecho")
Tony




PostPosted: Wed Dec 07, 2005 10:11 am   Post subject: (No subject)

you would use getch() when you're looking for a specific character (or set of)

Input.Pause works fine for waiting for any key (where is this "any key" anyways?
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 7 Posts ]
Jump to:   


Style:  
Search: