Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?

Re: Simulate "editable" keyboard input

by webfiend (Vicar)
on Dec 11, 2007 at 22:31 UTC ( #656501=note: print w/replies, xml ) Need Help??

in reply to Simulate "editable" keyboard input

It doesn't do you much good unless you want to be real adventurous, but in Perl 5.10 (available as a beta download on ActiveState) you'll be able to say:

use warnings; use strict; use 5.010; use Term::UI; use Term::ReadLine; my $term = Term::ReadLine->new(); my $filename = $term->get_reply( prompt => "Where is the file? ", default => "C:/Data/toload.txt", ); say "Filename: $filename";

The beta is available for Windows, but whether to use it or not is completely up to you.

Replies are listed 'Best First'.
Re^2: Simulate "editable" keyboard input
by FunkyMonk (Chancellor) on Dec 11, 2007 at 23:42 UTC
    Other than say, which is easily replaced by print, why does that need 5.10?

      Term::UI is listed as part of Core for 5.10, that's all. I just now had the silly realization that it could just be installed from CPAN as well.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://656501]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (8)
As of 2019-07-18 11:49 GMT
Find Nodes?
    Voting Booth?

    No recent polls found