Hack Forums
[.NET] DragDropControl - Example - Printable Version

+- Hack Forums (https://hackforums.net)
+-- Forum: Tech (https://hackforums.net/forumdisplay.php?fid=444)
+--- Forum: Coding (https://hackforums.net/forumdisplay.php?fid=151)
+---- Forum: Software Development (https://hackforums.net/forumdisplay.php?fid=118)
+---- Thread: [.NET] DragDropControl - Example (/showthread.php?tid=4240622)



DragDropControl - Example - Only3 - May 21, 2014

got this idea while googling

[Image: dd12882786c3c18515db462079d01033.gif]

Code
Class DragDropControl
    Inherits Control

    Public Property Control As Control = New PictureBox 'ListBox 'TextBox

    Public Sub New()
        Me.AllowDrop = True
        Me.Size = New Size(100, 100)
        Control.Dock = DockStyle.Fill
        If TypeOf Control Is TextBox Then CType(Control, TextBox).Multiline = True
        If TypeOf Control Is PictureBox Then CType(Control, PictureBox).SizeMode = PictureBoxSizeMode.StretchImage
        Me.Controls.Add(Control)
    End Sub

    Protected Overrides Sub OnDragEnter(e As DragEventArgs)
        If e.Data.GetDataPresent(DataFormats.FileDrop) Then
            For Each f In e.Data.GetData(DataFormats.FileDrop)
                If TypeOf Control Is TextBox Then Control.Text += f & vbCrLf
                If TypeOf Control Is ListBox Then CType(Control, ListBox).Items.Add(f)
                If TypeOf Control Is PictureBox Then CType(Control, PictureBox).ImageLocation = f
            Next
        End If
        MyBase.OnDragEnter(e)
    End Sub
End Class

🀝


* - Only3 - May 21, 2014

😊 look like ppl just looking to grab codes


* - SIM-1676753 - May 21, 2014

(May 21, 2014 02:39 PM)Only3 Wrote:  πŸ˜Š look like ppl just looking to grab codes

What did you expect, 40+ compliments? Nice shit though.


* - Only3 - May 22, 2014

didnt except anything i was talking in general about this section >> msgbox thread with +40 posts πŸ€¦β€β™‚


* - $lick - May 22, 2014

(May 21, 2014 02:39 PM)Only3 Wrote:  πŸ˜Š look like ppl just looking to grab codes

Are you new to hackforums?

Even the best projects get buried in an hour here with very few comments.


* - Only3 - May 22, 2014

(May 22, 2014 11:10 AM)ΰΉ–Ϋ£ΫœLazyβ„’ Wrote:  Are you new to hackforums?

(May 22, 2014 12:31 AM)Only3 Wrote:  didnt except anything i was talking in general about this section >> msgbox thread with +40 posts πŸ€¦β€β™‚
πŸ˜…
Even the best projects get buried in an hour here with very few comments.



* - SubGenius - May 22, 2014

If you 'release' code for people to admire you then you must be dumb.

Give time to your thread and explain what is this, how it works, and why we need it.
Then ppl will understand your work and learn from it.




(May 22, 2014 11:10 AM)ΰΉ–Ϋ£ΫœLazyβ„’ Wrote:  Even the best projects get buried in an hour here with very few comments.

Can't agree more. Many quality threads have been buried for the same reason OP did.


* - TheBarret - May 22, 2014

(May 21, 2014 05:39 PM)Mr. Trvp Wrote:  What did you expect, 40+ compliments? Nice shit though.

hes talking about "grabbing" more like hes leeching , i caught this moron in the act now. Hes a waste of space and oxygen.


* - $lick - May 22, 2014

(May 22, 2014 11:59 AM)TheBarret Wrote:  hes talking about "grabbing" more like hes leeching , i caught this moron in the act now. Hes a waste of space and oxygen.

Improving source that wasn't yours is not leaching.


* - SubGenius - May 22, 2014

(May 22, 2014 11:59 AM)TheBarret Wrote:  hes talking about "grabbing" more like hes leeching , i caught this moron in the act now. Hes a waste of space and oxygen.

Did he leeched the drag 'n drop function from you?
Oh, of course. Everyone is trying to copy from you. Only TheBarret codes unique applications.


* - TheBarret - May 22, 2014

(May 22, 2014 02:02 PM)Ho Lee Schitt Wrote:  Did he leeched the drag 'n drop function from you?
Oh, of course. Everyone is trying to copy from you. Only TheBarret codes unique applications.

Actually, yeah im pretty orginal arround here, proof me otherwise.


* - SubGenius - May 22, 2014

(May 22, 2014 02:37 PM)TheBarret Wrote:  Actually, yeah im pretty orginal arround here, proof me otherwise.

Don't get cocky bruh.
I agree that some your projects are really amazing and unique, no one can't argue with that.

But your attitude is shit. Really.
As much as I respect you for being an HQ coder, that much I find you annoying for making these LQ posts.


* - TheBarret - May 22, 2014

(May 22, 2014 03:55 PM)Ho Lee Schitt Wrote:  Don't get cocky bruh.
I agree that some your projects are really amazing and unique, no one can't argue with that.

But your attitude is shit. Really.
As much as I respect you for being an HQ coder, that much I find you annoying for making these LQ posts.

Im sorry that poke your balloon, but thats me. if it helps put me on the ignore list, case solved.


* - Only3 - May 24, 2014

(May 22, 2014 02:37 PM)TheBarret Wrote:  Actually, yeah im pretty orginal arround here, proof me otherwise.

original πŸ€¦β€β™‚ all ur projects and codes is from google πŸ˜–