Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Disabled time is a unique feature which enables developer to specify a portion of time when event creation is disabled without requiring complex efforts or codes. When the disabled time is specified, user will not be able to add a new or edit an existing event and set it within the range of specified disabled time period.

Since data operation cannot be performed in Quarter and Year view and Agenda view is text-based event information, disabled time feature is not implemented in these 3 views.

Featured In:

Use Disabled Time

Use Disabled Time in Month View

Panel

On this page:

Table of Contents
maxLevel3
stylecircle

Styles and Behavior 

  1. Cell styles in scheduler view
    In addition to blocked new event creation and editing, cells where the time is disabled will have different background color to indicate the disabled time indicator. Several styles properties are exposed for further customization on disabled time styles:

    • Day, Week, and Split view: DisabledAllDayEventAreaStyle, DisabledWorkHourStyle, and DisabledNonWorkHourStyle.
      Image Removed
      Image Added
                                             Disabled time style in Day, Week, and Split view


    • Month view: DisabledMonthOutboundCellStyle and DisabledMonthInboundCellStyle.
      Image Removed
      Image Added
                                         Disabled time style in Day, Week, and Split view


    • Timeline view: TimelineDisabledTimeCellStyle.

       Image RemovedImage Added
                                                                  Disabled time style in Timeline view


  2. Editing Form and CallOut
    CallOut or Editing Form will not appear when clicking on disabled time cell - preventing user from inserting a new event. Additionally, upon saving the event, an alert box will pop out.

  3. Context Menu
    New event, New Recurring Event and New All Day Event options in context menu will be disabled when clicking on disabled time cell.

Disabled Time Options

There are 3 disabled time options.

Global Disabled Time 

As the name implies, Global disabled time is applied to certain date and time and applied to all views. In Timeline view, the disabled time will be applied to all resources.

Code Block
titleXML
languagexml
<DisabledTime >

         <ISWebScheduler:WebSchedulerDisabledTime EndTime="2009-06-04" StartTime="2009-06-03">
         </ISWebScheduler:WebSchedulerDisabledTime>
</DisabledTime >

In Month and Timeline view, the following configuration will set 3rd of June 2009 as disabled time. Note that 4th of June 2009 are not included because the date range ends at that date.


Image RemovedImage Added
                              Global disabled time in Timeline View mode

Day, Week, and Split view contain two scheduler areas: the all-day area and hour area. The start time and end time of each disabled time will be used to indicate whether the all day area or hour area will be disabled.

The following configuration will set the 12th - 13th of March 2008 as disabled time. The start time and end time definition does not include time part, thus all-day area will be disabled.

Code Block
titleXML
languagexml
 <DisabledTime>
         <ISWebScheduler:WebSchedulerDisabledTime StartTime="2008-03-12" EndTime="2008-03-13">
         </ISWebScheduler:WebSchedulerDisabledTime>
</DisabledTime>


Image RemovedImage Added
                                         Global disabled all-day area in Week view


To disable the hour area, the complete date and time range must specified as disabled time collection. Below is an example on how to disable 10:00 AM - 12:00 PM on March 12th 2008.

Code Block
titleXML
languagexml
 <DisabledTime>
      <ISWebScheduler:WebSchedulerDisabledTime StartTime="2008-03-12 10:00:00" EndTime="2008-03-12 12:00:00">
      </ISWebScheduler:WebSchedulerDisabledTime>
</DisabledTime>


Image RemovedImage Added
                                                  Global disabled hour area in Week view

See Also:

Add Global Disabled Time in Timeline View

Add Global Disabled Time for All Day Area in Week View

Add Global Disabled Time for Hour Area in Week view

Resource Disabled Time 

Resource Disabled Time is a resource specific disabled time. This option lets developer specify a specific rule for each resource. Resource disabled time can only be set from code behind in OnDataBound server-side event. The disabled time collection will then be populated to each resource object using PopulateDisabledTime server-side method.

A code snippet on how to create resource disabled time in OnDataBound server side event.

Code Block
titleC#
languagec#
protected void WebScheduler1_DataBound(object sender, ISNet.WebUI.WebScheduler.WebSchedulerDataBoundDataArgs e)   
{       
   if (e.Type == ISNet.WebUI.WebScheduler.WebSchedulerObjectType.Resource)       
   {           
      WebSchedulerResource data = e.DataObject as WebSchedulerResource;           
      if (data.ResourceID == 1)           
      {               
         DataTable dt = new DataTable("DisabledTime");               
         DataColumn dc = new DataColumn("StartTime", Type.GetType("System.DateTime"));               
         DataColumn dc2 = new DataColumn("EndTime", Type.GetType("System.DateTime"));               
         DataColumn dc3 = new DataColumn("ResourceID", Type.GetType("System.Int32"));                             

         dt.Columns.Add(dc);               
         dt.Columns.Add(dc2);               
         dt.Columns.Add(dc3);                             

         DataRow dr = dt.NewRow();               
         dr["StartTime"] = new DateTime(2009, 6, 1);               
         dr["EndTime"] = new DateTime(2009, 6, 2);                              
         dt.Rows.Add(dr);                               

         dr = dt.NewRow();               
         dr["StartTime"] = new DateTime(2009, 6, 10);               
         dr["EndTime"] = new DateTime(2009, 6, 11);               
         dr["ResourceID"] = 1;               
         dt.Rows.Add(dr);                               

         WebSchedulerResource schedulerResource = e.DataObject as WebSchedulerResource;               
         schedulerResource.PopulateDisabledTime(dt, "StartTime", "EndTime");           
      }       
   }   
}


Image RemovedImage Added
                                    Resource specific Disabled Time in Timeline View mode

Resource disabled time can also be specified in Split view.

See Also:

Add Resource Disabled Time in Timeline View

Partial Disabled Time 

Partial disabled time is an extension of the disabled time concept in which not the entire day is disabled. Unlike the standard disabled time behavior, the Partial disabled time allows developer to specify certain disabled hours. To differentiate it from the global disabled time, a small padlock is added as a visual hint, which can be customized using ImagesSettings >> PartialTimelineDisabledTimeIcon property.

In the following screenshot, 9th of March 2009 01:00 PM to 02:00 PM is set as disabled time. Since only some part of the whole day is disabled, partial indicator is displayed at the bottom of the cell and the cell is considered as partial disabled cell.

Image RemovedImage Added
                                                       Partial disabled time in Timeline view

 

In Timeline view, the partial disabled time range can be displayed as tooltip when user hovers a disabled cell. To enable this feature, ViewSettings >> TimelineView >> DisplayDisabledTimeTooltip property needs to be set to true.

Image RemovedImage Added
                     Disabled time range is displayed as tooltip when disabled cell is hovered

See Also:

Add Partial Disabled Time in Timeline View


Related Topics

Content by Label
spaces@self
reversetrue
showLabelsfalse
max5
sortmodified
labelswebscheduler-features -disabled-time
showSpacefalse
typepage