Solved

how can we use Validations in Flash ?

Posted on 2009-04-15
3
218 Views
Last Modified: 2012-08-13
http://www.dotcompreview.com/kite.ie/custome_design.asp

I wants to put validations in include shorts, socks, sleeve length etc..
i wants to put validations in radio buttons and its custom made not from default flash library.

please find the attach jpg ( screen shot of above link )
Kite-ie---MENS---DESIGN-PAGE.jpg
0
Comment
Question by:dotsandcoms
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 39

Expert Comment

by:blue-genie
ID: 24191444
not sure what you're refering to by validations, are you wanting to check that a radio button is selected for example?
0
 

Author Comment

by:dotsandcoms
ID: 24191610
yes... by default all radio buttons are not checked. if any one forget to select i want to notify them that you have to select yes / no . and this radio button is not from Flash Components, its custom created.

just tell me if you want anything else....
0
 
LVL 39

Accepted Solution

by:
blue-genie earned 500 total points
ID: 24202982
ok i'm not sure how you've created your radio button.
but assume you have a button that you want to submit information but it needs to do validations first.

so what you can do is create a function to handle all your validations.

you didn't mention what version of AS you're using the following example is based on AS2 but it explains the logic. It also assumes your radio button has 2 frames for selected or not selected. did you build your radio buttons as components or just normal movie clips? if the latter you'll need to check each one individually as you aren't using radiogroups. so assume you have rd1 and rd2 as radiobuttons and first frame is not selected.

function validateSelections():Boolean {
if (rd1._currentFrame ==1 && rd2._currentFrame == 1 )
{
return false;
} else {
return true;
}
}

then on your button.

submit btn.onRelease = function () {
if (validateSelections) {
//they selected something carry on;
} else {
//none of the buttons were selected so notify accordingly.
}
}

0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
adobe product that creates checks to sales people for bringing sales 5 394
Array is not working ( AS2 ) 4 170
Adobe Flash Player ActionScript error 6 73
PDF edit software 2 62
Here are some practices and techniques that can be adopted into your Flash/Flex application development process. Note: Not all "performance tips" provide an immediately-recognizable benefit.   This article does not include timing validation data,…
In my long career of working as an actionscript developer, I had spent sleepless night often working hard to solve some small problems which actually took a lot of my development time; later found out the solutions to be a line or two. Here are s…
In this tutorial viewers will learn how to create a basic shape tween animation in Flash including shape hints for smooth animation Open a new document in Flash: Draw a shape: Select another frame (how long you want the tween to be): Right click and…
The goal of the tutorial is to teach the user how to use the auto adjust feature and what the different options do. When your video is not working right you can choose the auto adjust feature to help choose your settings.

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question