hi,
Basically when i tried to create TTMSFNCWXQRCode component, TFrame as a parent it raises “Invoke error: method not found”
it raises this error when i call create constructor, i tried it on windows its worked like charm but it looks like android issue.
i have FNCWebChromeClient.jar and JavaScriptHelper.jar in my sdk.
example code:
if profilePage=nil then
begin
profilePage := TFrameProfile.Create(Self);
profilePage.Parent := Self;
profilePage.Align := TAlignLayout.Contents;
end;
profilePage.LblDisplayName.Text := UserInfo.userDisplayName;
{$IF DEFINED(LINUX)}
{$ELSE}
if profilePage.ProfileQRCode=Nil then
Begin
try
profilePage.ProfileQRCode := TTMSFNCWXQRCode.Create(profilePage);//raises error
profilePage.ProfileQRCode.Parent := profilePage.clRcQRPanel;
profilePage.ProfileQRCode.Align := TAlignLayout.Client;
except
on E: Exception do
begin
RaiseException(e.Message,'[Profile QR Code]');
if profilePage.ProfileQRCode<>nil then
profilePage.ProfileQRCode.Free;
end;
end;
End;
if profilePage.ProfileQRCode<>Nil then
begin
if not UserInfo.AppUserGUID.IsEmpty then
begin
profilePage.ProfileQRCode.Text := UserInfo.AppUserGUID;
profilePage.ProfileQRCode.Visible := True;
end
else
begin
profilePage.ProfileQRCode.Text := 'Unknown';
profilePage.ProfileQRCode.Visible := False;
end;
end;
{$ENDIF}
Devices:
- Delphi 13
- Android 16