ActiveX Control on ASP.NET Page

Discussion in 'ASP .Net Web Controls' started by CSharpNewBie, Sep 28, 2005.

  1. CSharpNewBie

    CSharpNewBie Guest

    Hi

    I have a ActiveX control (TcpSocket Client) which has 3 Events
    OnConnect/OnDisconnect and OnEvent.
    my question is
    how do I embed this non-visual control on a aspx webpage and create a
    OnEvent Handler which receives data from a Tcp Server and add that to
    dataset to be displayed on DataGrid.

    This works fine a on Windows Application.

    Thanks in Advance.
     
    CSharpNewBie, Sep 28, 2005
    #1
    1. Advertising

  2. CSharpNewBie

    CSharpNewBie Guest

    Server Error in /WebApp Applcation

    Ok. I was able to get the ActiveX control to be created but now here's the
    error message
    Also the first Event works but not the second which has the EventSink

    Server Error in '/WebApp' Application.
    --------------------------------------------------------------------------------

    Exception from HRESULT: 0x80040202.
    Description: An unhandled exception occurred during the execution of the
    current web request. Please review the stack trace for more information
    about the error and where it originated in the code.

    Exception Details: System.Runtime.InteropServices.COMException: Exception
    from HRESULT: 0x80040202.

    Source Error:

    Line 36: this.asta.HostPort = 9000;
    Line 37: this.asta.OnConnect +=new
    IcaAlertReceiverXEvents_OnConnectEventHandler(asta_OnConnect);
    Line 38: this.asta.OnEvent +=new
    IcaAlertReceiverXEvents_OnEventEventHandler(asta_OnEvent);
    Line 39: this.asta.OpenConnection();
    Line 40: // Put user code to initialize the page here

    Source File: c:\inetpub\wwwroot\webapp\webform.aspx.cs Line: 38

    Stack Trace:

    [COMException (0x80040202): Exception from HRESULT: 0x80040202.]
    System.Runtime.InteropServices.UCOMIConnectionPoint.Advise(Object
    pUnkSink, Int32& pdwCookie) +0
    caAlertObject.IcaAlertReceiverXEvents_EventProvider.add_OnEvent(IcaAlertReceiverXEvents_OnEventEventHandler
    )
    caAlertObject.caAlertReceiverXClass.add_OnEvent(IcaAlertReceiverXEvents_OnEventEventHandler
    ) +0
    WebApp.WebForm1.Page_Load(Object sender, EventArgs e) in
    c:\inetpub\wwwroot\webapp\webform.aspx.cs:38
    System.Web.UI.Control.OnLoad(EventArgs e)
    System.Web.UI.Control.LoadRecursive()
    System.Web.UI.Page.ProcessRequestMain()



    Any help is appreciated.

    Thanks


    "CSharpNewBie" <> wrote in message
    news:%236$...
    > Hi
    >
    > I have a ActiveX control (TcpSocket Client) which has 3 Events
    > OnConnect/OnDisconnect and OnEvent.
    > my question is
    > how do I embed this non-visual control on a aspx webpage and create a
    > OnEvent Handler which receives data from a Tcp Server and add that to
    > dataset to be displayed on DataGrid.
    >
    > This works fine a on Windows Application.
    >
    > Thanks in Advance.
    >
    >
     
    CSharpNewBie, Sep 28, 2005
    #2
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Edward
    Replies:
    0
    Views:
    546
    Edward
    Jul 28, 2003
  2. Vincent Mouton
    Replies:
    0
    Views:
    446
    Vincent Mouton
    Apr 28, 2004
  3. CSharpNewBie

    ActiveX Control on ASP.NET Page

    CSharpNewBie, Sep 28, 2005, in forum: ASP .Net
    Replies:
    1
    Views:
    581
    Lucas Tam
    Sep 29, 2005
  4. =?Utf-8?B?QnVkaGkgU2FwdXRyYSBQcmFzZXR5YQ==?=

    Embbed .NET Custom Control (ActiveX) into ASP .NET page

    =?Utf-8?B?QnVkaGkgU2FwdXRyYSBQcmFzZXR5YQ==?=, Sep 13, 2006, in forum: ASP .Net
    Replies:
    6
    Views:
    508
    Seth Bourne
    Sep 19, 2006
  5. vml
    Replies:
    0
    Views:
    1,067
Loading...

Share This Page