A Flash Developer Resource Site

Results 1 to 7 of 7

Thread: Checkbox selection remotely

  1. #1
    Junior Member
    Join Date
    Jul 2002
    Posts
    6

    Checkbox selection remotely

    Hello there I have this need to implement a map showing different clicable areas in FLASH 8, so it can select and deselect each location by clicking directly to the location or by clicking a checkbox wich is near to the map it self.

    the thing is.. i managed my self to select and deselect the checkboxes from buttons contained inside an mc each button.

    this mc has 2 frames with one button each frame so in first frame it tells the ncheckbox to turn to selected AND to move nextFrame in the same mc where i putted another button so it could turn the selected state of that ncheckbox off AND to go to the prevFrame in the same mc

    Ok... So good so far!!!...

    Right now i noticed that i need to do almost same thing when i clic directly to the ncheckbox so when i clic and select the ncheckbox the mc containing the "remote trigger btn" would move to the nextFrame and when I clic and deselect the ncheckbox that same mc would move to the prevFrame.

    Right now im using the next script in the ncheckbox:

    on (click){
    if (ch_n1.selected = true) {
    _root.sel1.nextFrame();
    }else if(ch_n1.selected = false){
    _root.sel1.prevFrame();
    }
    }
    Where ch_n1 is the "ncheckbox" and sel1 is the mc containing the "remote trigger btn"

    and it works for the first evaluation.. (selected state) but it doesn't do any change when the "else" condition is reached

    I hope anyone can help me
    Last edited by lbaltodano; 06-21-2006 at 03:47 PM.
    Hi I'm Lautaro
    I hope this post is good enough for u!

  2. #2
    God yeps's Avatar
    Join Date
    Dec 2005
    Location
    :noitacoL
    Posts
    660
    hey im sry i read through that 2 or 3 times and i still cant figure out what you want... could you please simplify your request?

  3. #3
    Junior Member
    Join Date
    Jul 2002
    Posts
    6
    ok... i'll try to make it simple

    IMagine a map with different locations... well.. every location is a clicable selection wich needs to be included to make a query for a mysql db.

    ok.. i hope im being clear so far...

    so.. next to that map i need a locations list with checkboxes each one so user can actually track the locations he's clicking on.

    So .. when the user clics on a location over the map, the same checkbox with the locatino name needs to get selected (same case if it's deselected)

    BUT .. what if the user clics the checkbox directly?.. well.. in that case that location needs to change to the "selected" state too.

    A simple but good example is within this url:
    http://www.charlotteusa.com/Sites/sites_search.asp

    That example is a jpg and js I think.. but I need to do that in flash.. and to be able to control the selections made from both "locations over the map" and "checkboxes it selves"

    hope this time u get it . thanx in advance
    Hi I'm Lautaro
    I hope this post is good enough for u!

  4. #4
    Junior Member
    Join Date
    Jul 2002
    Posts
    6
    cmon people I really need help here...
    Hi I'm Lautaro
    I hope this post is good enough for u!

  5. #5
    God yeps's Avatar
    Join Date
    Dec 2005
    Location
    :noitacoL
    Posts
    660
    ok this might not be your problem but it doesnt look like your getting any other help

    would it matter if you had

    Code:
    ch_n1.selected == false
    instead of

    Code:
    ch_n1.selected = false

  6. #6
    Junior Member
    Join Date
    Jul 2002
    Posts
    6
    let me check ill let u know
    Hi I'm Lautaro
    I hope this post is good enough for u!

  7. #7
    Senior Member
    Join Date
    Apr 2006
    Posts
    1,059
    == is a comparision operator
    is checkbox equal to false?
    = is an assignment operator
    checkbox is equal to false!

    maybe that helps

Posting Permissions

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




Click Here to Expand Forum to Full Width

HTML5 Development Center