Why does the app close when I click edit1?

2

Personal the problem is as follows, I click on the button to create a new form, edit1 receives the focus, digital keyboard appears when I click on the letter a for example the app closes, why will it ?? Can anyone help ..?

procedure Tformadhor.FormClose(Sender: TObject; var Action: TCloseAction);
begin
  action := TCloseAction.caFree;
  formadhor:=nil;
  formrel.somarel(usua.Id);
  formrel.Show;
end;

procedure Tformadhor.FormShow(Sender: TObject);
begin
  edpub.SetFocus;
end;

procedure Tformadhor.Rectangle3Click(Sender: TObject);
begin
  close;
end;

procedure Tformadhor.Rectangle5Click(Sender: TObject);
begin
  salvareg;
  MultiView1.HideMaster;
end;

procedure Tformadhor.salvareg;
var 
  reg:TRegrel;
  db:TDM2;
begin
  reg:=TRegrel.create('null',m,y,strtoint(edpub.Text),strtoint(editvid.Text),
    edithora.Text,strtoint(editrev.Text),strtoint(editest.Text));
  db:=TDM2.Create(nil);
  if db.salvareg(usua,reg) then
    Showmessage('Salvo com Sucesso!!');
  db.DisposeOf;
end;

procedure Tformadhor.setusu(usu: TUsuario; nomemes: string; mes, ano: Integer);
begin
  Labnome.Text:=usu.nomecomp;
  labmes.Text:=nomemes;
  usua:=TUsuario.create('clone','','','',0);
  usua.clone(usu);
  m:=mes;
  y:=ano;
end;
    
asked by anonymous 11.04.2018 / 04:45

1 answer

2

You need a HotFix for the compiler, most likely that the JNI being used does not support the version of Android it is generating.

The Hotfix depends on the version of Delphi you are using and also on the version of Android that you want to compile.

Font

    
12.04.2018 / 13:11