1

Sorry for my ignorance,

I have a windows form in which I would like one of the panels to have fading effect. This link has provided the code that allows that to happen.

However I am really not sure how to synthesize them(my original winforms and his additionl usercontrol class) into the actual result that I want. It seems that I have to make a new project using User control as my main (referring to this link)? is that true?

Community
  • 1
  • 1
  • The first link gives you a `UserControl`. Drop it on your form. No new project required. The 2nd link doesn't help you. – DonBoitnott Aug 11 '14 at 11:13
  • You don't need a new project, just add a class to your existing project. Build your project, you now have a new control on the top of the toolbox that you can drop on the form. If you want to expand it then use the Inherited User Control item template. – Hans Passant Aug 11 '14 at 11:25
  • Thanks all!! Thanks Hans Passant, some amazing skill there =D – FailedMathematician Aug 13 '14 at 12:09

1 Answers1

0

You don't have to create a new project to create a user control. Just right click on your existing project in the Solution Explorer, hover on 'Add' option and click on 'User Control' in the context menu. Name your control in the popup window and the UserControl should be in your project. Open the .cs file and make the necessary changes as shown in the first link.

Once done, build your project and go to your designer. You should now see your UserControl listed in the Toolbox which you can use like any other normal control.

Shahid M Zubair
  • 515
  • 2
  • 7
  • 17