Re: Conversion component Meter/Feet-Inch



Hi Nils,

exist an component that conversion meter to feed/inch and backwards
???

There is a powerful, but easy to use, conversion system already built into your Delphi. Look at this example (untested!):

========

uses
ConvUtils, StdConvs;

function MetersToInches(const AValue: Extended): Extended;
begin
Result := Convert(AValue, duMeters, duInches);
end;

function MetersToFeets(const AValue: Extended): Extended;
begin
Result := Convert(AValue, duMeters, duFeet);
end;

function InchesToMeters(const AValue: Extended): Extended;
begin
Result := Convert(AValue, duInches, duMeters);
end;

function FeetsToMeters(const AValue: Extended): Extended;
begin
Result := Convert(AValue, duFeet, duMeters);
end;

========

--
Ivo Bauer
.



Relevant Pages

  • Re: Conversion component Meter/Feet-Inch
    ... function MetersToInches(const AValue: Extended): Extended; ... Result:= Convert(AValue, duMeters, duInches); ... Result:= Convert(AValue, duMeters, duFeet); ...
    (borland.public.delphi.thirdpartytools.general)
  • Re: Conversion component Meter/Feet-Inch
    ... Metres is the unit not Meters ... "Ivo Bauer" wrote in message ... function MetersToInches(const AValue: Extended): Extended; ... Result:= Convert(AValue, duMeters, duInches); ...
    (borland.public.delphi.thirdpartytools.general)