[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: MessageView
[Thread Prev] | [Thread Next]
- Subject: Re: MessageView
- From: Bruce Steers <bsteers4@xxxxxxxxx>
- Date: Fri, 4 Oct 2024 10:38:43 +0100
- To: user@xxxxxxxxxxxxxxxxxxxxxx
Dang sorry fella I've just woken up and am pre-coffee :-\ i think maybe i misread this and am way off base. On Fri, 4 Oct 2024 at 10:35, Bruce Steers <bsteers4@xxxxxxxxx> wrote: > I've been finding that Form_Open just does not always run when a form > opens (or rather, embeds) ! > > eg... > hMyInerForm.Load(hParentForm) > > The parent form opens and embeds the inner form okay but the inner forms > Form_Open event only fires if i do this.. > hMyInerForm.Load(hParentForm) > hMyInerForm.Show > > > Respects > BruceS > > > > > On Fri, 4 Oct 2024 at 06:16, BB <adamnt42@xxxxxxxxx> wrote: > >> Maybe I wasn't real good at explaining this. >> >> With a standalone form, whether it is the top level form or a popup, the >> message view doesn't try to show itself until MessageView1.Open is called. >> But when the form is opened as an embedded form in a tabpanel it appears to >> try and show the MessageView control. In the code for MessageView there is >> the GetTextWidth() method below. It fails and the execution aborts because >> $hIcon has not been set. >> >> I have no idea why it's trying to show the message panel just because the >> form is inside a tabpanel. >> >> b >> On 3/10/24 5:57 pm, BB wrote: >> >> This code doesn't cope when $hIcon has not been set. >> >> Private Sub GetTextWidth() As Integer >> >> Return Max(16, Me.Parent.ClientW - $hIcon.W - $hClose.W - Desktop.Scale * 6) >> >> End >> >> which happens when the MessageView has not been called yet, but it does run when the form is opened in a TabPanel. >> >> >> b >> >>
MessageView | BB <adamnt42@xxxxxxxxx> |
Re: MessageView | BB <adamnt42@xxxxxxxxx> |
Re: MessageView | Bruce Steers <bsteers4@xxxxxxxxx> |