Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms
Go Back  Xtreme Visual Basic Talk > > > Calling .DLL dragdrop function within WinForms


Reply
 
Thread Tools Display Modes
  #1  
Old 08-25-2015, 12:20 PM
StealthRT's Avatar
StealthRT StealthRT is offline
Contributor
 
Join Date: Aug 2002
Posts: 785
Question Calling .DLL dragdrop function within WinForms


I am looking for a example of how to get information from a WPF .dll (in a drag/drop mode) in my normal WinForm form.

As an example of what I am looking for:

Quote:
-The .dll has a round circle that can be moved around the screen.
-The circle, when moving around the screen, is in the "drag mode".
-Once the circle is released it's in "drop mode".
-Once dropped, I should be able to get its information (x,y,other info).
I have yet to find an example like the above one. I figured it would be configured (the .dll) to have public functions that return a value in the dropped state and my winform defining that .dll as a deleage in some type like so:

Code:
imports theDll.dll
    
    Private Function testingDropped()
       Dim testingDLL As New theDll.dll

       AddHandler testingDLL.DragDrop, AddressOf testingDLL_Drop
    End Function

    Private Function testingDLL_Drop()
       Msgbox("Yay it works!")
    End Function
And the DLL code would look something like so:

Code:
Private Sub aCircle_DragDrop(sender As Object, e As DragEventArgs) Handles aCircle.DragDrop
       Return "blah blah blah"
    End Sub
And this is where I am having an issue with and wondering how to go about getting the returned value *(blah blah blah in the example above)* within the Winforms code.

Or would it be more along the lines of this:

Code:
Public Declare Function testingDLL Lib "c:\Directory\test.dll" (ByVal BufferSize As String) As String
       Dim testingDLL As New theDll.dll

       AddHandler testingDLL.DragDrop, AddressOf testingDLL_Drop
    End Function

    Private Function (testingDLL_Drop)
       Dim theReturn as String = ""
    
       theReturn = getVersionID(returnedValue)
       messagebox.show(theReturn)
    End Function
So needless to say, I'm not sure what I need to call in order to do what I need to do.
The "DLL info" is not just getting information on the dll itself (version, save date, etc).. its the embedded information that i place inside its dragDrop function that returns data once dropped.

Any help would be great!
Attached Images
File Type: jpg flow4DLL.jpg (1.28 MB, 4 views)
Reply With Quote
  #2  
Old 08-25-2015, 03:02 PM
PlausiblyDamp's Avatar
PlausiblyDampCalling .DLL dragdrop function within WinForms PlausiblyDamp is offline
Ultimate Contributor

Forum Leader
* Expert *
 
Join Date: Nov 2003
Location: Newport, Wales
Posts: 2,058
Default

Do you have access to the DLL code?

What kind of app is the source of the drag / drop operation?

If you handle the DragDrop event in the target app what kind of inforamtion is available through the arguments to the event?
__________________
Intellectuals solve problems; geniuses prevent them.
-- Albert Einstein

Posting Guidelines Forum Rules Use the code tags
Reply With Quote
Reply

Tags
function, .dll, blah, private, testingdll_drop, information, dll, circle, string, thedll.dll, mode, dim, testingdll, dropped, return, thereturn, addhandler, public, testingdll.dragdrop, info, addressof, dragdrop, winforms, winform, screen


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Advertisement:





Free Publications
The ASP.NET 2.0 Anthology
101 Essential Tips, Tricks & Hacks - Free 156 Page Preview. Learn the most practical features and best approaches for ASP.NET.
subscribe
Programmers Heaven C# School Book -Free 338 Page eBook
The Programmers Heaven C# School book covers the .NET framework and the C# language.
subscribe
Build Your Own ASP.NET 3.5 Web Site Using C# & VB, 3rd Edition - Free 219 Page Preview!
This comprehensive step-by-step guide will help get your database-driven ASP.NET web site up and running in no time..
subscribe
Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms
 
Calling .DLL dragdrop function within WinForms
Calling .DLL dragdrop function within WinForms
 
-->