Hello,
We have been developing a currently in use application since 4 years. We decided to install on certain production workstations Windows 7 64 bits, I've also installed W7 64 on my development enviroment, we all were using Windows XP before; and development and production environments were running very stable.
Since the new upgrade we have noticed (including me), a redraw issue in one section of the application; this section (a very important one) contains multiple embedded controls, visualy we are using only the Devx Windows Forms Suite. The issue is only happening with 2 controls inserted on a Splitter Container control of your suite. Panel 1 contains a self made User Control with multiple DevExpress Controls and Panel 2 contains an XtraGrid.GridControl.
If you see the attached picture which contains 3 shots of the application, Shot 1 is the application running no maximized (1000x720 pixels), since we maximize the application as in Shot 2, a band of drawing garbage appears bellow the grid on Panel 2 and the user control on Panel 1, where a resize of these controls should be happening (please note both controls are docked Fill to container = Splitter Container Panels). Also the resizing problem is happening at the right of the grid control as you may notice. Once you click the splitter bar (collapse / restore) as in Shot 3, the controls with drawing issues they redraw/resize perfectly.
In a production environment this is a very annoying issue as you can imagine, because the users should be clicking everytime they have the problem on the splitter bar.
Also note that this is happening only on PCs having installed Windows 7, the rest of the users currently using Windows XP, they don't have the problem, they maximize or resize the application and redraw/resize is running fine.
We were using DevExpress suite 9.2.9, but i've upgraded to 10.2.3 on development environment to check if a bug fix would include this issue, but unfortunaly not. If you have any feedback about any king of problems on Windows 7 while redrawing certain controls, i would really appreciate you support.
Best Regards,
Ariel Garmendia
We have closed this ticket because another page addresses its subject:
Redrawing controls on Windows x64
Hi again,
The problem is related with the already documented nested forms issue on windows 7/vista 64 bits.
The solution/workaround is to include in the panel/form having the issue this code:
protected override void OnSizeChanged(EventArgs e)
{
if (Handle != null)
BeginInvoke((MethodInvoker)delegate{ base.OnSizeChanged(e); });
}
thanks in advance.
Ariel Garmendia
Hi Miguel,
I am afraid I cannot reproduce this issue on my side. Attached is a sample project, created based on your description, which works fine on my side in Windows 7 x64. It is possible that the issue is related to your user controls, or a specific layout. Please modify my project to reproduce the issue, and attach it to your next post.
Thanks,
Michael.
Hi Michael,
I've just posted the solution using a workaround already documented.
Please note that this issue, which would be more and more frecuent i think in the close future seeing the amount of users who will be updating theirs OS to any Windows 7 64 bits, should be taken in consideration when answering/questioning a Devx user.
regards
Ariel Garmendia
Hi Ariel,
I am glad to hear that you found a workaround. Could you please provide us with a link where this known issue is discussed?
Thanks,
Michael.
Hi Michael,
Well this issue is indeed related with a lot of different repaint issues on Windows 7/Vista 64 bits, and everything ends on this problem about the nesting hierarchy on these windows versions.
I started reviewing other problems about redrawing here in your KB articles, and i've just found this question:
http://devexpress.com/Support/Center/p/B142731.aspx
and then at the middle a colegue of yours Mr. Dimitros sends a link about this issue:
http://blogs.msdn.com/b/alejacma/archive/2008/11/20/controls-won-t-get-resized-once-the-nesting-hierarchy-of-windows-exceeds-a-certain-depth-x64.aspx
to finish, one of the commentaries of this post gratefully gives the solution i did use:
protected override void OnSizeChanged(EventArgs e)
{
if (Handle != null)
BeginInvoke((MethodInvoker)delegate{ base.OnSizeChanged(e); });
}
that's all i think
best regards
Ariel Garmendia
Hi Ariel,
Thank you for the additional information. I see that issue B142731 is fixed in versions 9.2.13, 9.3.7 and 10.1.7. I cannot reproduce that issue in the current version, either. It is possible that you are experiencing a different issue. However, we need a sample project, reproducing it, to be able to fix it.
Thanks,
Michael.
Hi Michael,
If at T - 1 i was having the painting problems and in T (time) when i only included this code to the application, the problem was solved? what does it mean?
regards
Ariel
Hi Ariel,
I also cannot reproduce the problem using the example project provided by Michael. However, I see that the layout on your screenshot is more complex. This fact, fact that this problem is reproduced on an x64 machine lead me to believe that the described issue is related to this bug: Vista 64 layout issue. This is also confirmed by the fact that the code you posted helps you. So, I believe that you found a correct solution.
Thanks,
Uriah.
Hi Uriah,
thanks a lot for your support and also to Michael,
regards
Ariel
You are welcome, Ariel!
Please feel free to contact us again, if you experience any difficulty when using our components.
Thanks,
Uriah.