Door Games Unlimited

Welcome, Guest.


Subject: console.getstr Date: Fri May 29 2015 23:14:17
From: Digital Man To: High Spirit

  Re: console.getstr
  By: High Spirit to All on Fri May 29 2015 11:02 am

 > Working on something and can't seem to figure it out. Looking at the
 > JavaScript Objet Model Reference for the getstr command, I see the usage:
 >
 > console.getstr([string] [,maxlen=128] [,mode=K_NONE])
 >
 > What is the [string] for?

It's the default value for the string for K_EDIT mode.

 > I was thinking it was a default value for the input but I cannot get that to
 > work.
 >
 > eg:
 >
 > console.print("Input Here: ");
 > console.getstr("value", 25, K_NOSPIN);
 >
 > would display:
 >
 > Input Here: value
 >
 > and the "value" would be highlighted and changed on first keystroke.
 >
 > Am I missing something or am I mis-interpreting what [string] is for?

Add the K_EDIT mode flag. (e.g. "K_NOSPIN|K_EDIT").

                                            digital man

Synchronet "Real Fact" #12:
Synchronet was the first BBS software to ship with internal QWK networking.
Norco, CA WX: 62.6°F, 81.0% humidity, 0 mph E wind, 0.00 inches rain/24hrs

---
 ■ Synchronet ■ Vertrauen ■ Home of Synchronet ■ telnet://vert.synchro.net

Previous Message       Next Message
In Reply To: console.getstr (High Spirit)
Replies: console.getstr (High Spirit)