Is it possible to drag and dropp applets onto a Windows form so that you could run them from a toolbar?
Printable View
Is it possible to drag and dropp applets onto a Windows form so that you could run them from a toolbar?
which applets are you talking about.
C# or Java.
what do you want to run from toolbar. elaborate your question.
Paresh
I need to have a toolbar done in C#, which will run applets, also done in C#.
Eric
what sort of applets you are talking about.
maybe you check out link
Paresh
These applets would be other programs written in C#.
ah ! I see now. you could have clarified that earlier. those are known as Controls or Custom User Controls. and not the Applet. the applet word is usually used for Internet world that's what I believe.
anyways...
now plz explain your problem further.
-Paresh
My question is, how do you enable dragging and dropping for a form/control? I enabled the AllowDrop property, but I still cannot drag and drop something onto my control. What I would like to do is to create custom user controls and then be able to drag them from Explorer onto my application and have them added to a control and have the custom control's icon appear on a button so it can be launched. Is this posslble, or is that a little bit of a stretch?
Eric
Hi,
If I am reading you correctly then,
>> typically you will need 2 controls for drag-drop.Quote:
My question is, how do you enable dragging and dropping for a form/control?
1) Source Control
2) Destination Control
now if you want to support the drag-drop operations then you will need to set Destination's AllowDrop property.
further you will need to handle drag-drop events. where you create the source object in drag region and then drag it on the destination control.
>> As, I said earlier you will need to handle the events for that. you can look in samples (if you want i can pass it to youQuote:
I enabled the AllowDrop property, but I still cannot drag and drop something onto my control.
;) )
>> so does that mean you are doing something like draging files on your control from the windows explorer.Quote:
What I would like to do is to create custom user controls and then be able to drag them from Explorer onto my application and have them added to a control and have the custom control's icon appear on a button so it can be launched
if not then,
when you create controls it will create a dll , you will need to reference it or add it in toolbox.
so that you can drag that control for further use.