Problem of throwing an exception (System.Net.Sockets.OverlappedAsyncResult::CompletionPortCallback)

Discussion in 'ASP .Net' started by VincentWong, Dec 29, 2003.

  1. VincentWong

    VincentWong Guest

    hi all,

    We're getting a security exception (An unhandled exception of type
    'System.Security.SecurityException' occurred in mscorlib.dll) on a
    asychronous
    callback(System.Net.Sockets.OverlappedAsyncResult::CompletionPortCallback).T
    his exception occurs when our control is embedded within an IE web page. A
    connection is established after calling a web service, it keeps opened for a
    period of time(observd by using netstat), it seems that when the connection
    is closed(timed out), the exception is thrown. When the web service is
    called again, no new connection is established(observed by using netstat),
    then an exception, "The operation has timed-out", is thrown. It seems that
    it tries to use the closed connection and it only happens when the control
    is embedded in the IE.

    Anybody have an idea solving this problem?

    Thanks

    Vincent
     
    VincentWong, Dec 29, 2003
    #1
    1. Advertising

  2. VincentWong

    VincentWong Guest

    Hi all,

    The problem is solved by setting the KeepAlive property of the
    WebRequest
    to False which force a new connection to be created for each call.

    Thanks

    Vincent

    "VincentWong" <vincent@no_email.com> wrote in message
    news:...
    > hi all,
    >
    > We're getting a security exception (An unhandled exception of type
    > 'System.Security.SecurityException' occurred in mscorlib.dll) on a
    > asychronous
    >

    callback(System.Net.Sockets.OverlappedAsyncResult::CompletionPortCallback).T
    > his exception occurs when our control is embedded within an IE web page. A
    > connection is established after calling a web service, it keeps opened for

    a
    > period of time(observd by using netstat), it seems that when the

    connection
    > is closed(timed out), the exception is thrown. When the web service is
    > called again, no new connection is established(observed by using netstat),
    > then an exception, "The operation has timed-out", is thrown. It seems that
    > it tries to use the closed connection and it only happens when the control
    > is embedded in the IE.
    >
    > Anybody have an idea solving this problem?
    >
    > Thanks
    >
    > Vincent
    >
    >
     
    VincentWong, Dec 29, 2003
    #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. =?Utf-8?B?R2xlbm4gVmVuemtl?=

    System.IO.Directoryinfo throwing exception

    =?Utf-8?B?R2xlbm4gVmVuemtl?=, Jul 25, 2005, in forum: ASP .Net
    Replies:
    3
    Views:
    3,741
    John Timney \(ASP.NET MVP\)
    Jul 25, 2005
  2. VincentWong
    Replies:
    0
    Views:
    184
    VincentWong
    Dec 19, 2003
  3. Tolga Erdogus

    System.Net.Sockets.OverlappedAsyncResult.Completio nPortCallback

    Tolga Erdogus, Nov 12, 2003, in forum: ASP .Net Web Services
    Replies:
    3
    Views:
    171
  4. VincentWong
    Replies:
    1
    Views:
    143
    Marshall Brooke
    Jan 15, 2004
  5. VincentWong
    Replies:
    1
    Views:
    167
    VincentWong
    Dec 29, 2003
Loading...

Share This Page