Jump to content

Strange closure of form.showmodal


AntonioCuomo

Recommended Posts

A unigui application consisting of FormLogin that launches a form with treemenu:

implementation

{$R *.dfm}

uses
  MainModule, uniGUIApplication, Bottiglie, Clienti, NuovoOrdine;

function UniForm_Menu: TUniForm_Menu;
begin
  Result := TUniForm_Menu(UniMainModule.GetFormInstance(TUniForm_Menu));
end;

procedure TUniForm_Menu.Clienti1Click(Sender: TObject);
begin
Form_Clienti.ShowModal();
end;

procedure TUniForm_Menu.NuovoOrdine1Click(Sender: TObject);
begin
Form_NuovoOrdine.ShowModal();
end;

procedure TUniForm_Menu.UniBitBtn1Click(Sender: TObject);
begin
 close;
end;

procedure TUniForm_Menu.Vini1Click(Sender: TObject);
begin
Form_Bottiglie.ShowModal();
end;

end.

 

All events that execute FormXXXX.showmodal when I close the form with CLOSE it returns to the FormMenu.
while with

procedure TUniForm_Menu.NuovoOrdine1Click(Sender: TObject);
begin
Form_NuovoOrdine.ShowModal();
end;

 

When the from is closed, it returns to the form_login and not to that of the Menu.

All forms are structured the same way.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...