Event colours based on Resources

Support for our integrated Contact Manager, Calendar, and Project Tracker.
Posts: 142
Joined: Thu Nov 01, 2012 2:36 pm
PostPosted: Sun Nov 04, 2012 2:16 am
Hi,
I have edited the resources value list and replaced the items with company vans. Each van has its own daily route and itinerary which may or may not clash with other vans.

On the calendar, these clashes/overlaps are flagged up with a red line and I'm not sure how to get around this problem. I can filter by van, which seems to work ok but it would be better if I could also change the colour of the event depending on the resource being used.

So, if I have vans A, B and C that each have a patrol visit to carry out at 21:00 can I change something so that each event has a different colour for easier identification?

Thanks
Brian.
SeedCode Staff
SeedCode Staff
Posts: 691
Joined: Mon Feb 28, 2011 2:47 pm
PostPosted: Mon Nov 05, 2012 9:28 am
Hi Brian,

You can have colors be based on any one field, and we use status by default. We have some documentation on changing this here:

http://www.seedcode.com/pmwiki/pmwiki.p ... ventColors

Let me know if that helps, or if you have any other questions on this.

Cheers!
Posts: 142
Joined: Thu Nov 01, 2012 2:36 pm
PostPosted: Mon Nov 05, 2012 10:35 am
Thanks Jason, I have that working fine now on the 'Resource' field...
Posts: 142
Joined: Thu Nov 01, 2012 2:36 pm
PostPosted: Wed Nov 14, 2012 4:13 pm
I changed the Weekly view so that each cell showed a coloured triangle just like the Daily view. I managed to do this fine but then noticed that the Daily view had changed to a full block of colour in the cell.

Can I have the coloured triangle on multiple views? I tried amending "Day" ; to "Day" ; "Night" ; but it didn't work.

Also, the page made reference to commenting out a section at the bottom to make the font bigger on the Weekly view but when I tried it, FM complained about an unknown command function or something. Could you have a look to see if there is a mistake with the code?

Thanks
Brian.
SeedCode Staff
SeedCode Staff
Posts: 691
Joined: Mon Feb 28, 2011 2:47 pm
PostPosted: Thu Nov 15, 2012 4:29 pm
Hi Brian,

Right the triangle is just meant for the day view and it seems like having it on the week view would be tricky as it's not designed for the different day columns there. Not sure why it would change the day view to a block.

brian.curran wrote:Can I have the coloured triangle on multiple views? I tried amending "Day" ; to "Day" ; "Night" ; but it didn't work.


Not quite following you here. Which views do you mean? We don't have anything for Night, so I'm not sure what you mean there either.

Also, the page made reference to commenting out a section at the bottom to make the font bigger on the Weekly view but when I tried it, FM complained about an unknown command function or something. Could you have a look to see if there is a mistake with the code?


Sorry, not sure what's happening here either. If you can give me more specifics as to the error it's throwing then I might know what it means, but I can't tell from this description.

If you want to send me the file, I'd be happy to take a quick look at it and see if that helps. Send it to [email protected]

Cheers!
Posts: 142
Joined: Thu Nov 01, 2012 2:36 pm
PostPosted: Fri Nov 16, 2012 2:27 am
I was following the instructions at http://www.seedcode.com/pmwiki/pmwiki.p ... ventColors In particular, this bit:

Can I use the triangle of color from the Simple Day View on other views?

Yes. The simple day view (go to Settings / click "Use simple...") uses a different display for colors so that the color doesn't fill the whole event.

If you want to use this display on other views, edit the calc CalendarColorReptCalc in the calendar rows table. The second line of this calc sets "objecto" to use our triangle display only when the mode is "Day" (our simple day mode). Edit this line to use the triangle in any other modes you'd like. For your reference, a list of possible modes can be found here.

You may also want to change the font size of the value "display" at the end of this calc just on the week and month views if you switch them to the triangle display. You'll see an example line there commented out which does this for you.


Apologies Jason, I meant to put "Week" instead of "Night" in my earlier post. At the bottom of the 'CalendarColorReptCalc' calculation is a line that can be commented out according to the instructions but when I try this, FM complains that "This Function cannot be found". I tried adding an = sign after Display but that didn't work either...

Thanks
Brian.
SeedCode Staff
SeedCode Staff
Posts: 691
Joined: Mon Feb 28, 2011 2:47 pm
PostPosted: Fri Nov 16, 2012 7:39 am
Got it Brian, and I probably should have figured that out too.

That's the general syntax error that FM shows when it can't resolve the calculation. It's hard to say what the actual problem is without seeing it, but if you uncomment that bottom part, you'll need to comment out the display that's already there so it looks like:

//display

If ( PatternCount ( $$sc_Mode ; "Week" ) ; TextSize ( display ; 14 ) ; display )

If you paste the whole calc you're trying to save in here when you get the error, we should be able to figure it out that way.

Thanks!

Return to SeedCode Calendar

Who is online

Users browsing this forum: No registered users and 2 guests

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