next up previous contents index
Next: Exec Up: Functions and Procedures Previous: EnvCount

EnvStr

   

Declaration:

Function EnvStr (Index: integer) : string;

Description:

EnvStr returns the Index-th Name=Value pair from the list of environment variables.

The index of the first pair is zero.

Errors:

The length is limited to 255 characters. This may cause problems under LINUX. The LINUX unit solves this problem.

See also:

EnvCount, GetEnv

Example
Program Example13;
uses Dos;

{ Program to demonstrate the EnvCount and EnvStr function. }

var
  i : Longint;
begin
  WriteLn('Current Environment is:');
  for i:=1to EnvCount do
   WriteLn(EnvStr(i));
end.



Michael Van Canneyt
Thu Sep 10 13:59:33 CEST 1998