|
|
||||||
|
||||||
| Index Link To US Private Messages Archive FAQ RSS | ||||||
| Flash Discussion Forum Flash design presents a limitless number of possibilities for your sites and designs. Discuss your Flash ideas, questions and issues here. |
Share Thread: & Tags
|
||||
|
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
West Technology Limited:Exclusive Values for Multiple Variables
The artcile was brought by the West Technology Limited Guys and Gals, I've got a new one for you that I haven't seen on the forum and I figured I'd put it out there while I figure out a solution. Here it goes: I've built an Ad Builder module (yeah!) that at one point has an option for bullet points for the ad. There are 5 combo boxes (they get to have 5 bullet points) with identical lists. Once a selection is made to a combo box, it changes the corresponding variable through a Change Handler function (thanks NTD!). Before the user is allowed to proceed to the next step, I check that all the fields are filled in (they can't have a blank bullet point). For all the other sections, this was easy because either there is a value for the variable or no value. For these combo boxes, the code to do that looks like this: _root.displaybuildcontent.displaynext2.onPress = function() { if ((_root.bull1 != null)&& (_root.bull2 != null)&& (_root.bull3 != null) && (_root.bull4 != null) && (_root.bull5 != null)) { nextFrame(); } else { _root.displaybuildcontent.required2._alpha=100; fieldCheck2(_root.bull1,_root.displaybuildcontent. requiredBull1); fieldCheck2(_root.bull2,_root.displaybuildcontent. requiredBull2); fieldCheck2(_root.bull3,_root.displaybuildcontent. requiredBull3); fieldCheck2(_root.bull4,_root.displaybuildcontent. requiredBull4); fieldCheck2(_root.bull5,_root.displaybuildcontent. requiredBull5); } }; The "_root.bull1"s are the variables. "_root.displaybuildcontent.required2" is the text box theat says "Required field", and the "_root.displaybuildcontent.requiredBull1"s are the asteriks for the specific combo box. The fieldCheck2 function code is this: function fieldCheck2(myVariable,myTarget){ if (myVariable != null){ myTarget._alpha = 0; } else { (myVariable == null) myTarget._alpha = 100; } }; This works great, because if any of the variables = null, it not only stops you from proceeding, it tells you which fields your missing, and rechecks the variables every time you press the "_root.displaybuildcontent.displaynext2" button (movieclip). Now, what I want to do is have it not only check that the variables != null before proceeding, but that the variables do not equal each other. I think it can be done with a huge if/else statement, but does anyone have a more refined way of comparing multiple variables' values not equalling each other? I'll keep working on it, but I thought I'd give the "experts" a try too. Thanks
__________________
Asia Domain Name Registration Limited bookmark from Domain Name and News |
|
|||
|
I need help
__________________
Asia Domain Name Registration Limited bookmark from Domain Name and News |
|
|||
|
......No one want to help me!
__________________
Asia Domain Name Registration Limited bookmark from Domain Name and News |
|
|||
|
Why not using Multiple-Selection List?
Cycling through a Multiple-Selection List : ListForm ControlJavaScript DHTML |
![]() |
|
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| West Technology Limited: Traffic Source: Expired Domains | Abiao25 | Domain Discussion Forum | 2 | 06-12-2008 04:28 AM |
| Cab.com in crazy sale--China Net Technology Limited | Elove | Domain Discussion Forum | 2 | 11-07-2007 09:35 PM |
| PHP - Using drop down form to pass multiple variables | richkoi | Web Programming Discussion Forum | 2 | 10-25-2005 01:25 PM |
| Temporary Variables: Keep Your Values Close, and Your Refer | WPW_Feedbot | Graphics & Design Discussion Forum | 0 | 09-30-2005 10:33 AM |
| multiple values from form in php | Jerry | Web Programming Discussion Forum | 3 | 09-20-2005 03:34 PM |
|
WebProWorld |
Advertise |
Contact Us |
About |
Forum Rules |
MVP's |
Archive |
Newsletter Archive |
Top |
WebProNews
WebProWorld is an iEntry, Inc. ® site - © 2009 All Rights Reserved Privacy Policy and Legal iEntry, Inc. 2549 Richmond Rd. Lexington KY, 40509 |