Button to left of each row to select entire week?

Integrating and modifying Proof's amazing mini-calendar.
Posts: 2
Joined: Mon Jul 23, 2012 6:59 am
PostPosted: Wed Jul 25, 2012 5:57 pm
Hey John!

Looking forward to your post Devcon reports :-)

Wondering if there is a relatively easy way to put a button to the left of each row of Ninjacal to be able to select that entire week with one click instead of click Sun, hold shift, click Sat? I tried to figure it out myself but couldn't find a way that didn't require quite a bit of code.

We are using Ninjacal for filtering our schedules it works great! Thanks again.

Best wishes,

~ Tyler

Tyler Tullock
Director
4/4 School of Music

Washington | Oregon | Texas

Website: http://www.44school.com
SeedCode Staff
SeedCode Staff
Posts: 691
Joined: Mon Feb 28, 2011 2:47 pm
PostPosted: Sun Jul 29, 2012 12:25 pm
Hi Tyler,

You can do this by setting the global variables manually and then running a refresh to see the highlighting, but not super easy.

For the first row you could get the "Saturday" by reading the NinjaCal::NinjaCal_basic[7] (seventh repetition), and then looping down from there to build your lists for $$__NinjaCalSelectedList and $$__NinjaCalSelectedNumbers.

You can get the numbers by using GetAsNumber() around the date value.

You can then build the $$__NinjaCalSelectedRange from the last and first dates in the $$__NinjaCalSelectedList.

The just call a refresh window and you'll see the highlighting update.

Let me know if that helps,
Jason
Posts: 2
Joined: Mon Jul 23, 2012 6:59 am
PostPosted: Sun Jul 29, 2012 10:56 pm
Thanks Jason,

A bit more complicated than I was hoping for but I will get it done with your suggestion. Thanks again and we are really enjoying NinjaCal.

Best wishes,

~ Tyler

Tyler Tullock
Director
4/4 School of Music

Return to NinjaCal

Who is online

Users browsing this forum: No registered users and 2 guests

cron
(855) SEEDCODE
[email protected]
Follow us: