Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: st: Re: Prompt user of ado file for input & output file names & path

From   Eric Booth <>
To   "<>" <>
Subject   Re: st: Re: Prompt user of ado file for input & output file names & path
Date   Mon, 4 Jul 2011 17:19:10 +0000


As Nick suggested, -dialog- boxes are what you want (especially to allow users to navigate folders); however,  I also like to use -display, request()- (see -help display-) and thought others may find it useful:

	**puts path in global macro $ans

**echo that back to the user:
window stopbox note `"PATH ENTERS AS :  $ans"'
di `"PATH ENTERED AS:  $ans"'

- Eric
Eric A. Booth
Public Policy Research Institute
Texas A&M University

On Jul 4, 2011, at 6:51 AM, Nick Cox wrote:

> . search dialog
> On Mon, Jul 4, 2011 at 12:47 PM, Partho Sarkar <> wrote:
>> This may be a very basic question!  I am writing an ado file which
>> will take a data file, perform some operations on the data, and write
>> the resulting data to another file.  How could I write commands to ask
>> the user to enter the names (with paths) of the input & output files?
>> This could be either in the form of displaying a text box/boxes for
>> the file names or, much more preferably, allow the user to browse (in
>> Windows) to the directory & input file.
> *
> *   For searches and help try:
> *
> *
> *

*   For searches and help try:

© Copyright 1996–2018 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index