Then you can't do it. Any more than *any* code in the browser can invoke ASP code on the server.<BR><BR>Oh, you probably *could* figure out a way to use "Remote Scripting" by invoking same from JS code that in turn talks to the control. But that's just another way of doing a "round trip" from client to server, which is the *ONLY* way of transferring info from one to the other.<BR><BR>
You can do what you want by declaring the event in the control.<BR><BR>Something like this:<BR>Public Event SomethingHappened<BR><BR>Then in your control, when the something happens, do a raise event. I can't remember the exact syntax now - I'd need to look at some of my controls at work.<BR><BR>Then in your JS client code, you'd have the event coded. Don't know JS too much, but here's the way you'd do it in VBScript:<BR><BR>Sub MyControl_SomethingHappened<BR> Msgbox "Something happened in my control!"<BR>End Sub<BR><BR>There is an ActiveX control development wizard (again, can recall the name, maybe the ActiveX Control Pad or something like that) that is GREAT for developing a "skeleton" of your control's code. I suggest getting that and using it. You'll learn a lot from that!