Code.GeekInterview.com
  I am new, Sign me up!
 
Code Samples Flash
 

Generation of Random Number


Code ResourceAuthor: lavanyarani  

Difficulty Level: Beginner

Published: 10th Nov 2009   Read: 627 times  

Filed in: Flash
Add Comment


 


Generating a random number using flash actionscript
 


Sample Code
  1. Step-1: Create an input box and give the name as “n”.
  2. Step-2: Create a button with the text on it “click”.
  3. Step-3: Select the button and open the action panel and write the
  4.              following code in the script pane.
  5.              on(release)
  6.             {
  7.                      n.text=Math.ceil(Math.random()*100);
  8.            }
  9.  Step-4: press ctrl+enter to test the movie.
  10.  
Copyright GeekInterview.com


Next Article: Creating Loops


 

Latest Code Samples

 

Popular Code Samples

 

Related Code Samples

 

Post Comment


Members Please Login

Name:  Email: (Optional. Used for Notification)

Title:
 
Comment:
Validation Code: <=>  (Enter this code in text box)





Popular Coders

# Coder NameHits
1. lavanyarani8210

Active Coders

# Coder NameCodes
1. lavanyarani13

Refined Tags

 

Sponsored Links

 
About Us -  Privacy Policy -  Terms and Conditions -  Contact  

Copyright © 2005 - 2010 GeekInterview.com. All Rights Reserved

Page copy protected against web site content infringement by Copyscape