Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Appointment Colour Programatically... (Read 2576 times)
Rob Branaghan
YaBB Newbies
*
Offline


I Love 2 Code!!

Posts: 16
Location: Warwickshire, England
Joined: Jan 6th, 2012
Appointment Colour Programatically...
Jan 13th, 2012 at 12:03pm
Print Post  
Hi,

How can I programatically change the styles of an appointment WITHOUT having to use Custom Draw?

All I want to be able to do is say...

app.Style = LateStyle;
or
app.Style = OnTimeStyle;

And it will colour the item as told.
At the moment everything is black?

It seemed to work for the guy before, he coloured things in Orange when Late.

if (EndTime > inputOperation.operationInfo.getDateReq())
{

Style.FillColor = Helper.MakeColourTransparent(Color.Orange);
Style.Brush = new MindFusion.Drawing.SolidBrush(Helper.MakeColourTransparent(Color.Orange));
Style.HeaderBrush = new MindFusion.Drawing.SolidBrush(Helper.MakeColourTransparent(Color.Orange));
PointedStyle.HeaderBrush = new MindFusion.Drawing.SolidBrush(Helper.MakeColourTransparent(Color.DarkOrange));
PointedSelectedStyle.HeaderBrush = new MindFusion.Drawing.SolidBrush(Helper.MakeColourTransparent(Color.Red));
SelectedStyle.HeaderBrush = new MindFusion.Drawing.SolidBrush(Helper.MakeColourTransparent(Color.DarkOrange));
SelectedStyle.FillColor = Helper.MakeColourTransparent(Color.FromArgb(colourList["DefaultHoverOperationBackground"]));
Faults = true;
}

Now, why does that work, and when I try and do same thing making items Green instead, it goes black???

Excuse the rather abrupt message, I have been banging my head against the monitor for 2 days now.
  

Robert Branaghan
.NET Software Developer
FactoryMaster Ltd.
Back to top
WWW  
IP Logged
 
Meppy
God Member
*****
Offline


MindFusion support

Posts: 1783
Joined: Jul 20th, 2005
Re: Appointment Colour Programatically...
Reply #1 - Jan 13th, 2012 at 12:56pm
Print Post  
Hi,

Can you also post the code that you are using to initialize the two styles (LateStyle and OnTimeStyle) as well as the current view?

Kind regards,
Meppy
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint