How to add the same control into multi panel in C#?

前端 未结 3 571
自闭症患者
自闭症患者 2021-01-18 14:49

I have a button called button1 and two panels called: panelA and panelB (visible is false by default) and the following code (WinForms):

panelA.Controls.Add(         


        
3条回答
  •  粉色の甜心
    2021-01-18 15:33

    I don't know why your seccond button are not visible. But, Why not to use two differents buttons with the same click event?

    Have you tried if the problem is still there is you try to add two different instances of a button?

    Good Luck.

提交回复
热议问题