Log In
Home
Support
Demos
Documentation
Blogs
Training
Webinars
[Expand]General Information
[Expand]WinForms Controls
[Collapse]ASP.NET Controls and MVC Extensions
 [Expand]Prerequisites
 [Expand]What's Installed
 [Expand]Common Concepts
 [Collapse]ASP.NET WebForms Controls
  [Expand]Reporting
  [Expand]Chart Control
  [Expand]Grid View
  [Expand]Card View
  [Expand]Vertical Grid
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Image and Data Browsing
  [Expand]Docking and Popups
  [Expand]Site Navigation and Layout
  [Expand]File Management
  [Expand]Multi-Use Site Controls
  [Collapse]Scheduler
   [Expand]Product Information
    Getting Started
   [Expand]Fundamentals
   [Collapse]Concepts
    [Expand]Scheduler Elements
    [Expand]Appointments
    [Expand]Resources
    [Expand]Views
     Data Binding
    [Collapse]Services
      Introduction to Services
      DateTime Navigation Services
      Resource Navigation Services
      Selection Service
      Appointment Selection Service
      Formatting Services
     Adaptivity
     Templates
     Client-Side Functionality
     Callback Commands
    [Expand]Reporting
     Time Zones
     Keyboard Shortcuts
   [Expand]Visual Elements
   [Expand]Design-Time Features
   [Expand]Examples
   [Expand]End-User Capabilities
   [Expand]Member Tables
  [Expand]HTML Editor
  [Expand]Pivot Grid
  [Expand]Tree List
  [Expand]Gauges
  [Expand]Data Editors
  [Expand]Spell Checker
  [Expand]Query Builder
 [Expand]ASP.NET MVC Extensions
 [Expand]Localization
 [Expand]Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Document Server
[Expand]Reporting
[Expand]Report Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

Formatting Services

Different parts of the application may require different formatting, especially for time and dates. A set of services is implemented to facilitate this task regarding the XtraScheduler Suite. These services are:

Expanded TimeRulerFormatStringService

ITimeRulerFormatStringService interface provides the means to custom format the text of time labels within the Time Ruler. You can override the following methods, substituting the service with its custom descendant:

  • GetHourFormat(TimeRuler ruler)
  • GetHalfDayHourFormat(TimeRuler ruler)
  • GetHourOnlyFormat(TimeRuler ruler)
  • GetTimeDesignatorOnlyFormat(TimeRuler ruler)
  • GetMinutesOnlyFormat(TimeRuler ruler)

These methods should return a format string specifying how to display a corresponding visual element. The location of elements within the time ruler is illustrated below.

TimeSlot.Value is 60 minutes:

TimeSlot.Value is 30 minutes:

Expanded HeaderCaptionService

IHeaderCaptionService interface enables you to change the captions of the headers in different views. You can override the following methods, substituting the service with its custom descendant:

  • string GetDayColumnHeaderCaption(DevExpress.Web.ASPxScheduler.Rendering.WebDateHeader header)
  • string GetDayOfWeekHeaderCaption(DevExpress.Web.ASPxScheduler.Rendering.WebDayOfWeekHeader header)
  • string GetHorizontalWeekCellHeaderCaption(DevExpress.Web.ASPxScheduler.Rendering.WebDateCellHeader header)
  • string GetTimeScaleHeaderCaption(DevExpress.Web.ASPxScheduler.Rendering.WebTimeScaleHeader header)
  • string GetVerticalWeekCellHeaderCaption(DevExpress.Web.ASPxScheduler.Rendering.WebDateCellHeader header)

The overridden method should return a format string specifying what to display in a header caption in the corresponding view.

Expanded HeaderToolTipService

IHeaderToolTipService interface allows you to specify custom tooltips for the day headers. You can override the following methods, substituting the service with its custom descendant:

  • string GetDayColumnHeaderToolTip(DevExpress.Web.ASPxScheduler.Rendering.WebDateHeader header)
  • string GetDayOfWeekHeaderToolTip(DevExpress.Web.ASPxScheduler.Rendering.WebDayOfWeekHeader header)
  • string GetTimeScaleHeaderToolTip(DevExpress.Web.ASPxScheduler.Rendering.WebTimeScaleHeader header)
  • string GetHorizontalWeekCellHeaderToolTip(DevExpress.Web.ASPxScheduler.Rendering.WebDateCellHeader header)
  • string GetVerticalWeekCellHeaderToolTip(DevExpress.Web.ASPxScheduler.Rendering.WebDateCellHeader header)

Overridden methods should return a format string specifying how to display a header's tooltip in the corresponding view.

Expanded AppointmentFormatStringService

IAppointmentFormatStringService interface provides the means to customize the time display format used in the visual representation of appointments. You can override the following methods, substituting the service with its custom descendant:

Overridden methods should return a format string specifying how to display a day header's tooltip in the corresponding view. The method for using this service is the same as described for the services above.

Show Me

A complete sample project is available in the DevExpress Code Examples database at http://www.devexpress.com/example=E1006.

Expanded See Also

How would you rate this topic?​​​​​​​