ASP.NET Chat

Discussion in 'ASP .Net' started by John Wright, Jul 29, 2004.

  1. John Wright

    John Wright Guest

    I am trying to create a very simple chat program using UDP through a web
    page. I am having problems getting this going. All the examples I've seen
    deal with remoting or application variables, or web services, etc. Does
    anyone have any resources to point me to (either VB.NET or C#) that explains
    how to create a simple chat on a web page?

    thanks.

    John
    John Wright, Jul 29, 2004
    #1
    1. Advertising

  2. John Wright

    Robert Guest

    http://cutesoft.net/Default.aspx?tabindex=1&tabid=23



    "John Wright" <> wrote in message
    news:e%...
    > I am trying to create a very simple chat program using UDP through a web
    > page. I am having problems getting this going. All the examples I've

    seen
    > deal with remoting or application variables, or web services, etc. Does
    > anyone have any resources to point me to (either VB.NET or C#) that

    explains
    > how to create a simple chat on a web page?
    >
    > thanks.
    >
    > John
    >
    >
    Robert, Jul 30, 2004
    #2
    1. Advertising

  3. John Wright

    bruce barker Guest

    a web page can not use UDP. you must supply a java applet, active/x control
    to do this. if you meant for the server to be a proxy for the chat client
    (talking to an internet chat), then you will need to spin up background
    threads that maintain the ip connections used by UDP, and set up some
    communication system between the connection managers and the aspx pages.

    -- bruce (sqlwork.com)


    "John Wright" <> wrote in message
    news:e%...
    > I am trying to create a very simple chat program using UDP through a web
    > page. I am having problems getting this going. All the examples I've

    seen
    > deal with remoting or application variables, or web services, etc. Does
    > anyone have any resources to point me to (either VB.NET or C#) that

    explains
    > how to create a simple chat on a web page?
    >
    > thanks.
    >
    > John
    >
    >
    bruce barker, Jul 30, 2004
    #3
  4. John Wright

    Dale Guest

    The problem with chat and the web is that the connection is not held between
    page requests. There's no way to send a message to the intended recipient
    unless the client requests the page by specific action of refreshing or
    submitting the form.

    You can hold messages in a database or even MessageQueue and update the
    client on refresh or on postback or there is another way I have used.

    I created a frames page, the client sends messages from one frame and in the
    other frame receives all messages intended for him. The page for the
    incoming messages frame is created with a class derived from IHttpHandler
    and IRequiresSessionState. I use a timer and a loop to keep the response
    object from completing so the connection between the client and server
    remains open and messages can be sent to the client as required. To prevent
    client timeouts, I Response.Write and empty string every minute.

    Another great chat starting point, and the starting point from which I
    developed a full function encrypted WindowsForms client/server chat system,
    is the DelegatesAndEvents example in the samples provided with the
    framework.

    There's also a TcpUdp chat example in the framework samples but I don't like
    it as much as the DelegatesAndEvents sample.

    Dale Preston
    MCAD, MCSE, MCDBA



    "John Wright" <> wrote in message
    news:e#...
    > I am trying to create a very simple chat program using UDP through a web
    > page. I am having problems getting this going. All the examples I've

    seen
    > deal with remoting or application variables, or web services, etc. Does
    > anyone have any resources to point me to (either VB.NET or C#) that

    explains
    > how to create a simple chat on a web page?
    >
    > thanks.
    >
    > John
    >
    >
    Dale, Aug 1, 2004
    #4
    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. OJO

    chat within asp.net?

    OJO, Jul 8, 2003, in forum: ASP .Net
    Replies:
    4
    Views:
    417
    Steve C. Orr, MCSD
    Jul 8, 2003
  2. Ken Cox [Microsoft MVP]

    Re: chat and offline message using asp.net

    Ken Cox [Microsoft MVP], Jul 20, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    452
    Ken Cox [Microsoft MVP]
    Jul 20, 2003
  3. Quentin

    chat about asp.net

    Quentin, Aug 2, 2003, in forum: ASP .Net
    Replies:
    0
    Views:
    339
    Quentin
    Aug 2, 2003
  4. Jason Cooke [MSFT]

    [ANN] August 3, "ADO.NET with Visual Basic .NET" chat

    Jason Cooke [MSFT], Aug 3, 2004, in forum: ASP .Net
    Replies:
    0
    Views:
    372
    Jason Cooke [MSFT]
    Aug 3, 2004
  5. Replies:
    0
    Views:
    2,190
Loading...

Share This Page