Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to solve the problem that panel overlap can not be displayed in winform in C #

2025-01-30 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/02 Report--

This article is about how to solve the problem that panel overlap can not be displayed in winform in C#. The editor thinks it is very practical, so I share it with you. I hope you can get something after reading this article. Let's take a look at it with the editor.

Panel overlap in winform in C # cannot display problems:

Recently, there is a requirement for developing a project that requires multiple modes to switch back and forth. I originally considered using multiple windows to achieve this function, but this is a waste of resources and a lot of work, so I want to use panel controls to solve this problem. But there is a problem in this process, that is, when multiple panel controls overlap, some panel controls can not be displayed. At first, I thought I deleted the panel control by mistake, but the compiler did not report an error when calling the control compiler that could not be displayed in the code. So you can be sure that the control is not deleted. Finally, it turns out that the level of the controls in the C#winform form is wrong, so I give the following solution.

Solution:

First of all, find out the missing controls, open the control window in VS2017, click View-> other windows-> document outline, and click to open document outline. As shown in the following figure:

We can see all the controls in the form in the document outline. All you need to do now is drag the controls you need to the appropriate level and rebuild the solution, as shown in the following figure:

When using multi-layer control overlap, it is easy to have the above problems. If you do not require high precision, you can make a little stagger between the controls, so that you can avoid such problems, and you can also set the controls to several overlaps of different sizes. The method depends on the requirements.

The above is how to solve the problem that panel overlap can not be displayed in winform in C#. The editor believes that there are some knowledge points that we may see or use in our daily work. I hope you can learn more from this article. For more details, please follow the industry information channel.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report