Professional Web Applications Themes

Closing connection of one user.. - Macromedia Flash Flashcom

now i'm busy with this sharedball thing, so each one that connects gets his own ball.. (with attach function) but now i want do de-attach when someone leaves. this someone might not be interested in clicking logout... (or disconnect) and he will click the window right away.. the ball will remain on screen ofcourse. now i want it to be de-attached when someone closes the (IE) window. I think this could be done by javascript but not everyone has javascript on, so thats not a good choise. Perhaps it could be done by some inside code in the SWF.. any ...

  1. #1

    Default Closing connection of one user..

    now i'm busy with this sharedball thing, so each one that connects gets his own
    ball.. (with attach function)
    but now i want do de-attach when someone leaves. this someone might not be
    interested in clicking logout... (or disconnect) and he will click the window
    right away..

    the ball will remain on screen ofcourse. now i want it to be de-attached when
    someone closes the (IE) window. I think this could be done by javascript but
    not everyone has javascript on, so thats not a good choise. Perhaps it could be
    done by some inside code in the SWF..

    any help would be appreciated

    Unknowner Guest

  2. #2

    Default Re: Closing connection of one user..

    There are a few ways this can be done, but all of them require that you start
    identifying your clients one way or another.

    The simplest way to do this is to set up a shared object with properties for
    each user, and have the clients respond to changes to those properties.

    If you have the PFCS book, there's a chapter with a chat component (chapter 15
    I believe) that illustates this quite well There are samples on the website
    (flash-communications.net). When a client joins the chat, a property is added
    to the SO, and the client side component adds the UI elements and handles the
    stream connections for the user. When the client leaves the room, the property
    in the SO is removed, and the clients respond accordingly.

    So, yes, you'll add some code to the .swf, but you'll also add some code to
    your SSAS.


    JayCharles Guest

Similar Threads

  1. Closing an ASP connection
    By htown in forum Macromedia Dynamic HTML
    Replies: 2
    Last Post: June 8th, 10:28 PM
  2. Closing one active ODBC connection
    By HSC Canada in forum Coldfusion Server Administration
    Replies: 5
    Last Post: February 28th, 02:49 PM
  3. closing a DB connection? ASP/VBScript
    By Nathon Jones in forum Macromedia Contribute Connection Administrtion
    Replies: 0
    Last Post: August 1st, 05:17 PM
  4. Closing Database Connection
    By patelajk in forum Dreamweaver AppDev
    Replies: 0
    Last Post: April 6th, 10:07 AM
  5. Commit on closing connection?
    By Ralf Assmann in forum IBM DB2
    Replies: 3
    Last Post: September 25th, 06:54 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139