|
web
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Me.Hide()frmDetails.ShowDialog() The only way I have provided to close this dialog is via the "X" button. If frmDetails is just closed as normal, there is no visual problem (no repainting) with the main form. Now, I add this code to the the FormClosing event in the dialog, frmDetails: If e.CloseReason = CloseReason.UserClosing Then e.Cancel = True Me.Hide() End If In this case, the dialog hides, but in the process there is unacceptable amount of repainting on the main form. A portion of the top right client area on the main form turns transparent for an instant showing portions of any underlying app that may be present. I gather that this transparency business is probably causing the repainting. Does anyone know if the Hide method has a bug? Better method? Workaround? Gene Im new to vb.. but have you tried instead of doing the Me.Hide() to just try
to set the Opacity of the form to 0 first? see if that work around solves ur display issue - then close the form? -I have not had that happen to me at all with my Dialog forms. ( vb2003 ) Miro Show quoteHide quote "gene kelley" <o***@by.me> wrote in message news:jluid2pm9s89nkv5hsfn9jp4i7ciajen40@4ax.com... > > I have a dialog form, frmDetails, that is opened from the main form: > > frmDetails.ShowDialog() > > The only way I have provided to close this dialog is via the "X" button. > > If frmDetails is just closed as normal, there is no visual problem (no > repainting) with the main > form. > > Now, I add this code to the the FormClosing event in the dialog, > frmDetails: > > If e.CloseReason = CloseReason.UserClosing Then > e.Cancel = True > Me.Hide() > > End If > > In this case, the dialog hides, but in the process there is unacceptable > amount of repainting on the > main form. A portion of the top right client area on the main form turns > transparent for an instant > showing portions of any underlying app that may be present. I gather that > this transparency > business is probably causing the repainting. > > Does anyone know if the Hide method has a bug? Better method? > Workaround? > > Gene On Wed, 9 Aug 2006 11:29:55 -0400, "Miro" <miron***@golden.net> wrote: The Opacity value of the dialog has no effect with regards to the problem. It's the actual call to>Im new to vb.. but have you tried instead of doing the Me.Hide() to just try >to set the Opacity of the form to 0 first? > >see if that work around solves ur display issue - then close the form? > >-I have not had that happen to me at all with my Dialog forms. ( vb2003 ) > >Miro > > Hide versus Close that triggers the problem. It now appears that the problem is being caused by a 3rd party control in use in this particular app. If I temporarily remove it, the problem goes away, so I'm now checking with the control vendor on this issue. Gene Show quoteHide quote >"gene kelley" <o***@by.me> wrote in message >news:jluid2pm9s89nkv5hsfn9jp4i7ciajen40@4ax.com... >> >> I have a dialog form, frmDetails, that is opened from the main form: >> >> frmDetails.ShowDialog() >> >> The only way I have provided to close this dialog is via the "X" button. >> >> If frmDetails is just closed as normal, there is no visual problem (no >> repainting) with the main >> form. >> >> Now, I add this code to the the FormClosing event in the dialog, >> frmDetails: >> >> If e.CloseReason = CloseReason.UserClosing Then >> e.Cancel = True >> Me.Hide() >> >> End If >> >> In this case, the dialog hides, but in the process there is unacceptable >> amount of repainting on the >> main form. A portion of the top right client area on the main form turns >> transparent for an instant >> showing portions of any underlying app that may be present. I gather that >> this transparency >> business is probably causing the repainting. >> >> Does anyone know if the Hide method has a bug? Better method? >> Workaround? >> >> Gene >
FileListBox from VB6?
Help with first VB application - Data Entry form Easy Value Compare Question MS VB Newbie Tutorial Check to see if a server is running Check if a Windows service running Writing to a file opened in another class CreateObject does not work consistently in X64 systems add row ro gridview Software process question |
|||||||||||||||||||||||