[Webinar] Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Rolling Money Counter

Posted on 2005-05-05
6
Medium Priority
?
263 Views
Last Modified: 2008-03-06
I need to make a "Digital Counter" that from the start of the Flash Movie goes from 0 to "anynumber" that we input.

Example...we have a fund raiser going on and we want the $$ to run up from $0 to $40,241 this week and next week be able to have it go to $41,955

I'd like to do this in Flash MX so that I can add a rising 3D column that comes up as the dollars rise. If I could tie the column to the rising $$'s so much the better.

I currently have a three frame movie but am getting error messages

Frame 1
  var money=0;
  var howhigh=1000;

Frame 2 has a dynamic text box with an instance name of 'money' and the following code
   if(money<howhigh){
   money++;
   }

Frame 3
  gotoAndPlay(2);

I'm not getting any error messages...nor am I getting anything at all for that matter.

I'm using Macromedia Flash MX 7.  It's obvious that I'm not an action script guy...

A little help here?
0
Comment
Question by:lrbrister
  • 3
  • 3
6 Comments
 
LVL 18

Accepted Solution

by:
Billystyx earned 2000 total points
ID: 13935002
I have a fla for download at http://www.billystyx.co.uk/setups/raisingmoney.zip


Billystyx
0
 
LVL 18

Expert Comment

by:Billystyx
ID: 13935023
frame2 I changed to this:

   if(money<howhigh){
   money++;
   moneydollars="$"+money+".00";
   percent=money/howhigh*100;
 
   bar._yscale=percent;
   }

and I added a mc column instance name 'bar', with a background mc with no instance name and a different colour.

Billystyx
0
 

Author Comment

by:lrbrister
ID: 13935155
Billystyx,
  Thanks...I'll definately be awarding the points to you in a moment.
Question...is there a way to "step" the dollars by 10's or hundred's so it loads faster?

Reason...

I may need to show this on a screen where we want to go up to $ 15,000.00
0
Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

 

Author Comment

by:lrbrister
ID: 13935202
Also...the bar doesn't "rise" with the money.  Can we make it match the money and come up like a rising thermometer?
0
 

Author Comment

by:lrbrister
ID: 13935263
Sorry...
I was wrong on the bar chart...it rises.

But can I get the "step"  or "increment" by 100 ?
0
 
LVL 18

Expert Comment

by:Billystyx
ID: 13935339
change this line
money++;
to
money= money+10;

Billystyx
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

I have been doing hardcore actionscripting for some time; and needless to say I have faced a lot of problems in just understanding others' code rather than understanding what the code executes. A programmer's life can become hell when there are a lo…
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 select the video input device. Make sure you have an input device that in connected and work and recognized by Adobe Flash Media Live Encoder and select it in the “video input” menu.
Suggested Courses
Course of the Month20 days, 12 hours left to enroll

864 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