Copy link to clipboard
Copied
as the title suggest Slider Effect cannot go over 1 million. this is very annoying and hard to understand in 2019. (also unbelievably number effect cannot go over 30.000)
i am tring do animate a youtube view counter that goes over 1 million.
using this expression on a empty text layer
n = 0+effect("Slider Control")("Slider"); < THIS IS THE SLIDER CONTROL
s = "" + n;
str = s.substr(-s.length, (s.length-1)%3 +1);
for (i = Math.floor((s.length-1)/3); i > 0; i--){
str += "," + s.substr(-i*3,3);
}
str
Any work around? or alternative tecniques?
Google Dan Ebbert’s universal timer. Second option, don’t try to do everything on one layer. Try using three text layers, one for the commas, one for the first thousand, the third for the millions. Unless you’re actually counting teal and have more than about 6 million frames, there’s no way in the world anyone will be able to tell your counter doesn’t show every digit.
Another option, if you want to count to 1,000,000 over 10 seconds just calculate on multiplier for your slider or just use time
...Copy link to clipboard
Copied
If you don't need units precision, just multiply the slider value by a factor.
Copy link to clipboard
Copied
Google Dan Ebbert’s universal timer. Second option, don’t try to do everything on one layer. Try using three text layers, one for the commas, one for the first thousand, the third for the millions. Unless you’re actually counting teal and have more than about 6 million frames, there’s no way in the world anyone will be able to tell your counter doesn’t show every digit.
Another option, if you want to count to 1,000,000 over 10 seconds just calculate on multiplier for your slider or just use time.
10 seconds = 300 frames, 1,000,000 / 300 = 333.3
So just multiply the result of your expression by 333 and animate the slider from 0 to 3333.3 over 10 seconds.
Copy link to clipboard
Copied
thx guys, tried the multiplication tricks and seems to be working fine.
but in the meantime i did it in c4d and just rendered the sequence, one would think ae should be good for this kind of tasks, but personally i find c4d much better...much more versatile and intuitive
but thx!
Copy link to clipboard
Copied
You can also multiply by a second slider. This way you can have values from 1 to over a billion.
Copy link to clipboard
Copied
I use the Point Control effect and add this expression to the Source Text:
s = "" + Math.round(effect("Point Control")("Point")[0]);
s.replace(/\B(?=(\d{3})+(?!\d))/g, ",");
Works for me and is simpler than multiplying the slider value.
Copy link to clipboard
Copied
Thanks Katie! This expression and effect works a treat! I got to the 3 million easy!
Copy link to clipboard
Copied
this expression doesn't work for me ? 😞
Copy link to clipboard
Copied
@katie.landers thank you so much for this! @Emma247663742737 with just a little tweak of what Katie provided, I got it to work:
s = "$" + Math.round(effect("Point Control")("Point")[0]).toLocaleString();
s.replace(/\B(?=(\d{3})+(?!\d))/g, ",");
this.sourceText = s;
Note the difference is I'm adding in the "$" at the start because I was displaying in USD. The "toLocaleString();" bit at the end adds the commas. The "this.sourceText = s;" bit is what actually displays the text in the empty text object - which is where I included the code.