Note also that prompt__ is equivalent to prompt_base_

Thanks,

-- 
Raul

On Wed, Feb 18, 2015 at 4:54 PM, Brian Schott <[email protected]> wrote:
> Pascal,
>
> I am using prompt in jconsole and jhs, so wd seems irrelevant to me.
> On the other hand let me show prompt here in this message to make it easier
> for others to better see the issue.
>
>    prompt
> 3 : 0
> '' prompt y
> :
> if. IFQT do.
>   wd 'sm prompt ',y,x
>   inp=. 1!:1 ] 1
>   len=. #y
>   (len * y -: len {. inp) }. inp
> else.
>   y 1!:2 (IFWIN+.IFJHS+.IFIOS) { 4 2
>   1!:1 ] 1
> end.
> )
>
>
> Also, the verb `ask` uses prompt but requires prompt__ as it is used below.
> To be clearer, I added the __ because ask through a value error without it.
> Notice that the whole script is written to the locale 'panimals' (at the
> top of the script).
>
> ask=: 3 : 0
>   while. 0=#last=: tolower deb '?'-.~ prompt__ ,&'? ' y do. end.
>   if. (<last) e. ;:'quit restart' do. throw. end.
>   last
> )
>
> The entire script is at the link supplied in the original post. I had to
> revise the original script's `require` for prompt because prompt.ijs has
> moved over time. The revision is included in my original post, also.
>
> Thanks,
>
>
>
> On Tue, Feb 17, 2015 at 10:44 AM, 'Pascal Jasmin' via Programming <
> [email protected]> wrote:
>
>> in j802+,
>>
>> wd 'mb input text "enter animal" "type here then press ok: " "default cow"'
>>
>> seems useful.
>>
>>
>>
>> --
> (B=)
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to