unit xRegistry; interface uses Registry; type tRegistry=class(Registry.tRegistry) private public function ReadIntegerDef(const Name:string; Def:Integer):integer; function ReadBoolDef(const Name:string; Def:boolean):boolean; end; implementation function tRegistry.ReadIntegerDef(const Name:string; Def:Integer):integer; begin Result:=Def; try If GetDataType(Name)=rdInteger then Result:=ReadInteger(Name); except end; end; function tRegistry.ReadBoolDef(const Name:string; Def:boolean):boolean; begin Result:=Def; try if GetDataType(Name)=rdInteger then Result:=ReadBool(Name); except end; end; end.