Appointment: Hide time and location, show only summary

7 posts, 1 answers
  1. manuele
    manuele avatar
    22 posts
    Member since:
    Oct 2010

    Posted 12 Mar 2015 Link to this post

    Hi, 
      i would like to ho hide the time and the location on my appointments on the scheduler

    Is it possible?

  2. Stefan
    Admin
    Stefan avatar
    2891 posts

    Posted 13 Mar 2015 Link to this post

    Hi Manuele,

    Thank you for writing.

    Please refer to the AppointmentTitleFormat property information in the following article: http://www.telerik.com/help/winforms/scheduler-appointments-and-dialogs-working-with-appointments.html.

    I hope that you find this information useful. Should you have any other questions, do not hesitate to contact us.

    Regards,
    Stefan
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  3. UI for WinForms is Visual Studio 2017 Ready
  4. manuele
    manuele avatar
    22 posts
    Member since:
    Oct 2010

    Posted 13 Mar 2015 in reply to Stefan Link to this post

    Hi, thank you so much

    I have tried like this: 

    Me.RadScheduler1.AppointmentTitleFormat = "{6}{2}{7}"

    It's works but i would like to remove semicolon, is it possible?
  5. Answer
    Stefan
    Admin
    Stefan avatar
    2891 posts

    Posted 13 Mar 2015 Link to this post

    Hi Manuele,

    Unfortunately, the semi column cannot be removed at present. What I can do for you is to expose the method responsible for creating the text, so you can customize it. This can be included in the upcoming service pack in the beginning of April. If this is OK for you, here is the code which you would be using with our new version:
    Protected Overrides Sub OnLoad(e As EventArgs)
           MyBase.OnLoad(e)
     
           AddScheduler()
           Me.radScheduler1.AppointmentTitleFormat = "{6}{2}{7}"
           radScheduler1.ElementProvider = New MyElementProvider(radScheduler1)
       End Sub
     
       Public Class MyElementProvider
           Inherits SchedulerElementProvider
           Public Sub New(scheduler As RadScheduler)
               MyBase.New(scheduler)
           End Sub
           Protected Overrides Function CreateElement(Of T As SchedulerVisualElement)(view As SchedulerView, context As Object) As T
               If GetType(T) Is GetType(AppointmentElement) Then
                   Return TryCast(New MyAppointmentElement(Me.Scheduler, view, CType(context, IEvent)), T)
               End If
     
               Return MyBase.CreateElement(Of T)(view, context)
           End Function
       End Class
     
       Public Class MyAppointmentElement
           Inherits AppointmentElement
           Public Sub New(scheduler As RadScheduler, view As SchedulerView, appointment As IEvent)
               MyBase.New(scheduler, view, appointment)
           End Sub
     
           Protected Overrides Function CreateAppointmentText() As String
               Return MyBase.CreateAppointmentText().Replace(";", "")
           End Function
       End Class

    I hope that you find this information.

    Regards,
    Stefan
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  6. manuele
    manuele avatar
    22 posts
    Member since:
    Oct 2010

    Posted 13 Mar 2015 in reply to Stefan Link to this post

    For me it is ok, but i have just one last problem:

    When i try to override CreateAppointment function i get an error
    it seems that the function is private

    Thanks a lot

  7. Stefan
    Admin
    Stefan avatar
    2891 posts

    Posted 13 Mar 2015 Link to this post

    That is correct. I mentioned that in my previous post. I have exposed this method and this will be included in the upcoming service pack in the beginning of April. Once we release it, you can download it and you can apply the above code with it.

    I hope this clears things up.

    Regards,
    Stefan
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  8. manuele
    manuele avatar
    22 posts
    Member since:
    Oct 2010

    Posted 13 Mar 2015 in reply to Stefan Link to this post

    Ok, thanks
Back to Top
UI for WinForms is Visual Studio 2017 Ready