I get the error:
"$" is not a valid integer value
when I try to set up TMSFNCDatabinder for TMSFNCColorPicker.
What is to be done?
We have fixed this issue, the next version of TMS FNC Core will address this. To fix this, open TMSFNCGraphics.pas unit and change the HTMLToColor function to:
class function TTMSFNCGraphics.HTMLToColor(AHTML: string): TTMSFNCGraphicsColor;
var
r,g,b: Integer;
begin
Result := gcNull;
if AHTML = '' then
Exit;
if Length(AHTML) = 4 then
begin
r := StrToInt('$' + Copy(AHTML,2,1) + Copy(AHTML,2,1));
g := StrToInt('$' + Copy(AHTML,3,1) + Copy(AHTML,3,1));
b := StrToInt('$' + Copy(AHTML,4,1) + Copy(AHTML,4,1));
end
else
begin
r := StrToInt('$' + Copy(AHTML,2,2));
g := StrToInt('$' + Copy(AHTML,4,2));
b := StrToInt('$' + Copy(AHTML,6,2));
end;
{$IFDEF CMNWEBLIB}
Result := RGB(r, g, b);
{$ELSE}
Result := MakeGraphicsColor(r, g, b);
{$ENDIF}
end;