C1 Calendar with SuperToolTip

WinForms

ComponentOne's WinForms controls

C1 Calendar with SuperToolTip

  • rated by 0 users
  • This post has 8 Replies |
  • 1 Follower
  • Hi All,

    Some guidance please.

    I have a set of events and their dates in a DB which I would like to show as bold days in a C1Calendar control. I then want to be able to hover over that date to display a SuperToolTip with the events details.

     Can this be done?

     Thanks

    Shai

  • > Some guidance please.
    >
    > I have a set of events and their dates in a DB which I would like to show as bold days
    > in a C1Calendar control. I then want to be able to hover over that date to display a
    > SuperToolTip with the events details.
    >
    > Can this be done?

    This feature will be available in 2009 V1 version.

    You should subscribe to C1Calendar.BeforeDayTooltipShow event and supply desired html
    formatting in event handler for this event:

    private void c1Calendar1_BeforeDayTooltipShow(object sender,
    BeforeDayTooltipShowEventArgs e)
    {
    if (e.Day.DayOfWeek == DayOfWeek.Sunday)
    {
    e.Text = "Sunday";
    }
    else
    {
    e.Cancel = true;
    }
    }
  • Hi Irina,

    Thank you for your reply.

    When will V1 2009 be available?

    The code you have given is relevant to the new version?

     

    Thanks

    Shai

  • > When will V1 2009 be available?
    >
    > The code you have given is relevant to the new version?
    Yes.

    I'm not aware about release date.
    Untested build is available here:
    http://download3.componentone.com/pub/Net/c1schedule/misc/C1Schedule.2_2.0.20091.92.zip

    You can use it for development puproses while waiting for release version.
  • Thanks Irina,

     Ive downloaded the untested build, copied the C1.Win.C1Schedule.2.dll and C1.Win.C1Schedule.2.XML files to

     C:\Program Files\ ComponentOne Studio.NET 2.0\bin  and P:\QFG-EnquiryCentre\bin\debug

    but still get the following build errors

    The type or namespace name 'C1Schedule' does not exist in the namespace 'C1.Win' (are you missing an assembly reference?) 

    P:\QFG-EnquiryCentre\ucSeminar.cs 
    Error 2 The type or namespace name 'C1Schedule' does not exist in the namespace 'C1.Win' (are you missing an assembly reference?) 

     

  • Try to remove C1Schedule reference from your project, add it back and re-build.
  • Excellent, that worked! Thank you.

    Unfortunately I get runtime errors, something about Thickness not being a valid Int32, and other FormatExceptions when I load the form that parents the Calender control.

    I guess I'll just have to wait till the next version is released. :(

    Thanks for your help.

  • > Excellent, that worked! Thank you.
    >
    > Unfortunately I get runtime errors, something about Thickness not being a valid Int32,
    > and other FormatExceptions when I load the form that parents the Calender control.
    I haven't heard of such issues.
    Try to reset VisualStyle of all C1Calendar and C1Schedule controls on your form (you can
    do that at design-time from context menu).
    If issue persists, send me (to IrinaP at componentone.com) either the simple application
    reproducing the problem or full exception stack trace.
  • I had to remove the following two lines of code form the designer.cs for my form:

     

    this.calEvents.Theme.XmlDefinition = resources.GetString("resource.XmlDefinition");

    this.calEvents.VisualStyle = C1.Win.C1Schedule.UI.VisualStyle.Custom;

    I then had to reset my custom appearance and it worked.

     

    Thanks.

Page 1 of 1 (9 items)