简体   繁体   中英

C# User control - Drag and drop and custom propertis

I have simple user control in VS2017 (picture below) User control

在此处输入图片说明 Now I wont to use this control in my application using drag and drop. Not in VS toolbox but in application. Additionally I want to have properties window like in picture above in my application. The questions are:

  1. How to get properties window like in picture above when user drag and drop control in application for example user put this control in container in application?

  2. What code I need to allow user for drag and drop control?

You can give me example or link to tutorials and the I will try to write all code.

Concerning question 1:

if you want to show such a property window in your application, you have to write it yourself and get all properties and their values using reflection.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM