> > {===}
> > program contest;
> > uses windows;
> >
> > var
> > info:tSTARTUPINFO;
> >
> > begin
> > GetStartupInfo(@info);
> > if ( info.hStdInput = 0 )
> > then {Started from Explorer}
> > else {Started from Console}
> > end.
> > {===}
>
> > > > Is it possible for a program to tell whether it was started
> > > > from the command line or started by double-clicking on the
> > > > application icon?
> If you want to use Win API calls, I think
> this would be a better (and simpler) way to do it:
>
>
> {===
> > > Is it possible for a program to tell whether it was started
> > > from the command line or started by double-clicking on the
> > > application icon?
> > {=}
> > program envtest;
> > uses Dos;
> > var
> > F:text;
> > i:LongInt;
> > begin
> > assign(F, 'envlist.txt
>
> Under Win98, there are some subtle differences in the output of the program
> below, when run from a DOS window vs. double-clicking the icon.
> I don't know if this will work for NT-based OS, though
>
> {=}
> program envtest;
> uses Dos;
> var
> F:text;
> i:LongI
On Wed, 3 Aug 2005, Jean-Marc Chourot wrote:
Hi all,
Could someone help to understand what happens with this piece of code :
When I call the following function, I very very often receive an error
:MCIERR_PARAM_OVERFLOW: writeln(err,' The output string was not long
enough.');
Does anybody know