Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Java Build a JavaFX Application It's About Time Timeline and Animations

Nancy Melucci
PLUS
Nancy Melucci
Courses Plus Student 36,143 Points

Can't figure out not obvious from video or application code...

I am sure I am missing it but I've watched the video repeatedly, looked at my application code and still don't have a clue. From the quiz...

"If we wanted to run the keyframes (or pages) 5 times we'd write the following code:"

timeline.set____________(5);

2 Answers

Andrew Winkler
Andrew Winkler
37,739 Points

If you look back to 1:50 in the Timeline Animation video, you'll find that your looking for the setCycleCount() method.

Therefore the code should be:

timeline.setCycleCount(5);

If this was helpful, please vote best answer! Happy coding!

chase singhofen
chase singhofen
3,811 Points

super helpful. i need to pay attention in videos more. i was typing keyFrames instead which is wrong. thx