Bei FormCreate rufe ich die folgende Procedure auf:
Code:
procedure SetWebbrowserMode(Mode: TIEMode; AppName: string = '');
const
REG_KEY = 'Software\Microsoft\Internet Explorer\Main\FeatureControl\FEATURE_BROWSER_EMULATION';
var
Reg: TRegistry;
Value: Integer;
begin
if AppName = '' then AppName := ExtractFileName(Application.ExeName);
Case Mode of
iemIE7 : Value := $1B58;
iemIE8 : Value := $1F40;
iemIE10 : value := $2710;
iemIE11 : Value := $2af8;
end;
Reg := TRegistry.Create();
try
Reg.RootKey := HKEY_CURRENT_USER;
if Reg.OpenKey(REG_KEY, True) then
begin
Reg.WriteInteger(AppName, Value);
Reg.CloseKey;
end;
finally
Reg.Free;
end;
end;
Mit WebBrowsers Speicherproblem hat das aber nichts zu tun.