Embedded Winform - trapping event in host javascript

F

Fresno Bob

Hi I am using an embedded winform control to do some drag and drop
functionality on an intranet site. I one bit of functionality I can't
get to work is firing event and trapping it in the host javascript of
the web page. All the examples are in C# and suspect there is
something I am doing wrong.
http://bytes.com/topic/net/answers/...-net-winforms-user-control-back-javascript-ie
here is one the examples I have been using

<Guid("5F61E14B-9121-47cd-BB8E-A0C2B4F3BD3D")> _
<ComVisible(True)> _
<InterfaceType(ComInterfaceType.InterfaceIsIDispatch)> _
Public Interface IDragEvent
<DispId(1)> _
Event Dropped()
End Interface

<ComVisible(True)> _
<ComSourceInterfaces(GetType(IDragEvent))> _
Public Class ucDragDrop
Implements IDragEvent
Public Event droppedfile() Implements IDragEvent.Dropped

Private _FilePaths As String

Public Property FilePaths() As String
Get
Return _FilePaths
End Get
Set(ByVal value As String)
_FilePaths = value
End Set
End Property


Private Sub Button1_Click(ByVal sender As System.Object, ByVal e
As System.EventArgs) Handles Button1.Click
RaiseEvent droppedfile()
End Sub
End Class



<script for="objFiles" event="Dropped()" language="javascript">
alert("window control event happen!");
</script>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,578
Members
45,052
Latest member
LucyCarper

Latest Threads

Top