Moving an event between 2 dates

Hi,

Can anyone help me with a bit of advice on how to code a couple of allowable date ranges between which I can move a records date fields.  I’m using DbPlannerMonthView to display a table with 4 datetime columns – StartDate (StartTimeField), FinishDate (EndTimeField), EarlyDate &  LateDate. 

I only want to be able to move the start and finish dates between the early and late date ranges.  Is it possible to stop the user from dragging the bar past the allowed range?  Also in a similar way, can I bring up a warning message if I only want to advise them that the date range is “out of bounds” How can I achieve this?  Any help would be appreciated.

Colin

Just in case it matters... I'm using Delphi XE

You'd typically do this by implementing the OnItemMoving event and set the parameter Allow = false for the moves you want to disallow.

Thanks for steering me in the right direction Bruno, that was nice and easy to implement.

Col