Convert BinToInt

Function BinToInt ( Value : String ) : Integer ;
Var
i ,
Size : Integer ;
Begin
Result := 0
;
Size :=
Length ( Value ) ;
For i :=
Size Downto 1 Do
If Value[ i ] = '1' Then Result := Result + ( 1 Shl ( Size - i ) ) ;
End ;
Example
:
Caption := IntToStr ( BinToInt ( '11111111' ) ) ;