On Wed, 19 Feb 2003, milimeter wrote:

> Hello, everybody
>
>   I wrote the following code in program foo.pp:
> >>>>>>>>>
>   writeln(ParamStr(1));
> <<<<<<<<<
>   And when I run it with a parameter "foo *.txt", I mean to get "*.txt", but
> unfortunately, it prints out "test.txt", where test.txt is a file under the
> same directory. I know the shell extends my command to "foo test.txt". How
> can I get the original parameter without the extension of shell?

You cannot. If you want that, you must type
  foo "*.txt"
on the shell command line.
There is nothing FPC can do about this, the shell has expanded all arguments
already before the FPC program is invoked.

Michael.

_______________________________________________
fpc-pascal maillist  -  [EMAIL PROTECTED]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal

Reply via email to