RobYost Posted February 12, 2017 Share Posted February 12, 2017 ---------------------------Debugger Exception Notification---------------------------Project -.exe raised exception class EAssertionFailed with message 'TUniSimplePanel.SetParent(): Parent.OwnerForm must be same as Self.OwnerForm (H:\Framework\uniGUI\Source\Core\uniGUIClasses.pas, line 4837)'.---------------------------Break Continue Help --------------------------- I reduced it down to this. procedure TfraTIncome.btnNewChargeClick(Sender: TObject);var aFrame: TUniFrame; aTempModalForm: TUniForm;begin aTempModalForm := TUniForm.Create(UniApplication); aFrame := TUniFrameClass(TUniFrame1).Create(self); aFrame.Parent := aTempModalForm ;end; Quote Link to comment Share on other sites More sharing options...
RobYost Posted February 12, 2017 Author Share Posted February 12, 2017 It looks like it has to be a real form. And The code must be in that form. If I move that code to a different unit it fails. Quote Link to comment Share on other sites More sharing options...
Abaksoft Posted November 9, 2017 Share Posted November 9, 2017 Hello; Change : Self by aTempModalForm procedure TfraTIncome.btnNewChargeClick(Sender: TObject);var aFrame: TUniFrame; aTempModalForm: TUniForm;begin aTempModalForm := TUniForm.Create(UniApplication); aFrame := TUniFrameClass(TUniFrame1).Create(aTempModalForm); aFrame.Parent := aTempModalForm ;end; That works fine Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.