Jump to content

parent form


donlego

Recommended Posts

hi .. it try to create runtime form with unitabsheet as parent of the runtime form

this my code

procedure TMainForm.do_CreateTab(acaption: string);
var
 atab: TUniTabSheet;
 aform: TUniForm;

begin
   atab := TUniTabSheet.Create(self);
   with atab do
   begin
     Caption := acaption;
     PageControl := UniPageControl1;
     PageControl.ActivePage := atab;
   end;

   aform := TUniForm.Create(UniApplication);
   with aform do
   begin
     Caption := acaption;
     Parent:=atab;
     show;
   end;
 
end;

 

it's work in desktop mode but in browser mode has an error

access violation at address 00445AE4 in modeule project1.exe write of address bla bla..

is there something wrong with my code or ??

 

thanks ...

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...