>From: "Christian Hernoux" <cnhx@polisoft.fr>
>To: "Informix List" <informix-list@rmy.emory.edu>
>Subject: How can i get an env. variable
>Date: Wed, 5 Nov 1997 12:58:33 +0100
>X-Informix-List-Id: <list.17226>
>
>Message en plusieurs parties et au format MIME.
Maybe, but at least some Mime-Enabled Mailers couldn't read it...
Specifically, pine 3.60 couldn't.
>------=_NextPart_000_0008_01BCE9EA.86588AE0
> charset="iso-8859-1"
>
>I use i4gl ver. 4.11.UC4. How can i get an env. variable ?
>Does exist a fg??? fonction ?
Possibly. There is an fgl_getenv() function in later versions
of I4GL; it should be present in 4.11 too, but I don't have that
version available to verify that.
If it isn't there, you can use this version:
#include <stdlib.h>
int fgl_getenv(int nargs)
{
char envvar[64];
if (nargs != 1)
fgl_fatal("fgl_getenv", 0, -1318);
popquote(envvar, sizeof(envvar));
retquote(getenv(envvar));
return(1);
}
Yours,
Jonathan Leffler (johnl@informix.com) #include <witticism.h>