SPECIAL OFFER        Order and save right now!
20% off with the 729824315 dicscount code for Ultimate Pack and any another product for Delphi from Greatis Programming!

⤷ Expand environment strings

If you have some environment variable (for example, '%WinDir%'), then you may use ExpandEnvironmentStrings function to get a real value of this variable.

procedure TForm1.Button1Click(Sender: TObject);
var
  Str: array [0..255] of Char;
begin
  if ExpandEnvironmentStrings(PChar(Edit1.Text), Str, 256)>0 then
    Label1.Caption:=Str;
end;
Related components
TFileSearch
TFolderMonitor
TFileVersion
More for developers
Databases for Amazon Associates
Amazon Categories
Amazon Nodes