Reconfigure for GIT

This commit is contained in:
2017-03-26 20:00:03 +02:00
commit 00637826ab
8056 changed files with 535977 additions and 0 deletions
@@ -0,0 +1,28 @@
<%@ Control Language="vb" AutoEventWireup="true" Inherits="UserForms_AppointmentDragToolTip" Codebehind="AppointmentDragToolTip.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.v15.2" Namespace="DevExpress.Web"
TagPrefix="dxe" %>
<div style="white-space:nowrap;">
<dxe:ASPxLabel ID="lblInterval" runat="server" Text="CustomDragAppointmentTooltip" EnableClientSideAPI="true">
</dxe:ASPxLabel>
<br />
<dxe:ASPxLabel ID="lblInfo" runat="server" Text="Press ESC to cancel operation" EnableClientSideAPI="true"></dxe:ASPxLabel>
</div>
<script id="dxss_ASPxClientAppointmentDragTooltip" type="text/javascript"><!--
ASPxClientAppointmentDragTooltip = _aspxCreateClass(ASPxClientToolTipBase, {
CalculatePosition: function(bounds) {
return new ASPxClientPoint(bounds.GetLeft(), bounds.GetTop() - bounds.GetHeight());
},
Update: function (toolTipData) {
var stringInterval = this.GetToolTipContent(toolTipData);
var oldText = this.controls.lblInterval.GetText();
if (oldText != stringInterval)
this.controls.lblInterval.SetText(stringInterval);
},
GetToolTipContent: function(toolTipData) {
var interval = toolTipData.GetInterval();
return this.ConvertIntervalToString(interval);
}
});
//--></script>
@@ -0,0 +1,33 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class UserForms_AppointmentDragToolTip
'''<summary>
'''lblInterval control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblInterval As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''lblInfo control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblInfo As Global.DevExpress.Web.ASPxLabel
End Class
@@ -0,0 +1,34 @@
Imports Microsoft.VisualBasic
Imports System
Imports System.Data
Imports System.Configuration
Imports System.Collections
Imports System.Web
Imports System.Web.Security
Imports System.Web.UI
Imports System.Web.UI.WebControls
Imports System.Web.UI.WebControls.WebParts
Imports System.Web.UI.HtmlControls
Imports DevExpress.Web.ASPxScheduler
Partial Public Class UserForms_AppointmentDragToolTip
Inherits ASPxSchedulerToolTipBase
Public Overrides ReadOnly Property ClassName() As String
Get
Return "ASPxClientAppointmentDragTooltip"
End Get
End Property
Public Overrides ReadOnly Property ToolTipShowStem() As Boolean
Get
Return True
End Get
End Property
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
DevExpress.Web.ASPxWebControl.RegisterBaseScript(Page)
End Sub
Protected Overrides Function GetChildControls() As Control()
Dim controls() As Control = { lblInterval }
Return controls
End Function
End Class
@@ -0,0 +1,332 @@
<%--
{************************************************************************************}
{ }
{ DO NOT MODIFY THIS FILE! }
{ }
{ It will be overwritten without prompting when a new version becomes }
{ available. All your changes will be lost. }
{ }
{ This file contains the default template and is required for the form }
{ rendering. Improper modifications may result in incorrect behavior of }
{ the appointment form. }
{ }
{ In order to create and use your own custom template, perform the following }
{ steps: }
{ 1. Save a copy of this file with a different name in another location. }
{ 2. Specify the file location as the 'OptionsForms.AppointmentFormTemplateUrl'}
{ property of the ASPxScheduler control. }
{ 3. If you need custom fields to be displayed and processed, you should }
{ accomplish steps 4-9; otherwise, go to step 10. }
{ 4. Create a class, derived from the AppointmentFormTemplateContainer, }
{ containing custom properties. This class definition can be located }
{ within a class file in the App_Code folder. }
{ 5. Replace AppointmentFormTemplateContainer references in the template }
{ page with the name of the class you've created in step 4. }
{ 6. Handle the AppointmentFormShowing event to create an instance of the }
{ template container class, defined in step 4, and specify it as the }
{ destination container instead of the default one. }
{ 7. Define a class, which inherits from the }
{ DevExpress.Web.ASPxScheduler.Internal.AppointmentFormController. }
{ This class provides data exchange between the form and the appointment. }
{ You should override ApplyCustomFieldsValues() method of the base class. }
{ 8. Define a class, which inherits from the }
{ DevExpress.Web.ASPxScheduler.Internal.AppointmentFormSaveCallbackCommand. }
{ This class creates an instance of the AppointmentFormController inheritor }
{ (defined in step 7) via the CreateAppointmentFormController method and }
{ overrides the AssignControllerValues method of the base class to collect }
{ user data from the form's editors. }
{ 9. Handle the BeforeExecuteCallbackCommand event. The event handler code }
{ should create an instance of the class defined in step 8, and specify it }
{ as the destination command instead of the default one. }
{ 10. Modify the overall appearance of the page and its layout. }
{ }
{************************************************************************************}
--%>
<%@ Control Language="vb" AutoEventWireup="true" Inherits="AppointmentForm" Codebehind="AppointmentForm.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web" TagPrefix="dxe" %>
<%@ Register Assembly="DevExpress.Web.ASPxScheduler.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxScheduler.Controls" TagPrefix="dxsc" %>
<%@ Register Assembly="DevExpress.Web.ASPxScheduler.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxScheduler" TagPrefix="dxwschs" %>
<table class="dxscAppointmentForm" cellpadding="0" cellspacing="0" style="width: 100%; height: 230px;">
<tr>
<td class="dxscDoubleCell" colspan="2">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell">
<dxe:ASPxLabel ID="lblSubject" runat="server" AssociatedControlID="tbSubject" Text="Subject:">
</dxe:ASPxLabel>
</td>
<td class="dxscControlCell">
<dxe:ASPxTextBox ClientInstanceName="_dx" ID="tbSubject" runat="server" Width="100%" Text='<%#(CType(Container, AppointmentFormTemplateContainer)).Appointment.Subject%>' />
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="dxscSingleCell">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell">
<dxe:ASPxLabel ID="lblLocation" runat="server" AssociatedControlID="tbLocation" Text="Location:">
</dxe:ASPxLabel>
</td>
<td class="dxscControlCell">
<dxe:ASPxTextBox ClientInstanceName="_dx" ID="tbLocation" runat="server" Width="100%" Text='<%#(CType(Container, AppointmentFormTemplateContainer)).Appointment.Location%>' />
</td>
</tr>
</table>
</td>
<td class="dxscSingleCell">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell" style="padding-left: 25px;">
<dxe:ASPxLabel ID="lblLabel" runat="server" AssociatedControlID="edtLabel" Text="Label:">
</dxe:ASPxLabel>
</td>
<td class="dxscControlCell">
<dxe:ASPxComboBox ClientInstanceName="_dx" ID="edtLabel" runat="server" Width="100%" DataSource='<%#(CType(Container, AppointmentFormTemplateContainer)).LabelDataSource%>' />
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="dxscSingleCell">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell">
<dxe:ASPxLabel ID="lblStartDate" runat="server" AssociatedControlID="edtStartDate" Text="Start time:" Wrap="false">
</dxe:ASPxLabel>
</td>
<td class="dxscControlCell">
<dxe:ASPxDateEdit ID="edtStartDate" runat="server" Width="100%" Date='<%#(CType(Container, AppointmentFormTemplateContainer)).Start%>' EditFormat="DateTime" DateOnError="Undo" AllowNull="false" EnableClientSideAPI="true" >
<ValidationSettings ErrorDisplayMode="ImageWithTooltip" EnableCustomValidation="True" Display="Dynamic"
ValidationGroup="DateValidatoinGroup">
</ValidationSettings>
</dxe:ASPxDateEdit>
</td>
</tr>
</table>
</td>
<td class="dxscSingleCell">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell" style="padding-left: 25px;">
<dxe:ASPxLabel runat="server" ID="lblEndDate" Text="End time:" Wrap="false" AssociatedControlID="edtEndDate"/>
</td>
<td class="dxscControlCell">
<dxe:ASPxDateEdit id="edtEndDate" runat="server" Date='<%#(CType(Container, AppointmentFormTemplateContainer)).End%>' EditFormat="DateTime" Width="100%" DateOnError="Undo" AllowNull="false" EnableClientSideAPI="true">
<ValidationSettings ErrorDisplayMode="ImageWithTooltip" EnableCustomValidation="True" Display="Dynamic"
ValidationGroup="DateValidatoinGroup">
</ValidationSettings>
</dxe:ASPxDateEdit>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="dxscSingleCell">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell">
<dxe:ASPxLabel ID="lblStatus" runat="server" AssociatedControlID="edtStatus" Text="Show time as:" Wrap="false">
</dxe:ASPxLabel>
</td>
<td class="dxscControlCell">
<dxe:ASPxComboBox ClientInstanceName="_dx" ID="edtStatus" runat="server" Width="100%" DataSource='<%#(CType(Container, AppointmentFormTemplateContainer)).StatusDataSource%>' />
</td>
</tr>
</table>
</td>
<td class="dxscSingleCell" style="padding-left: 22px;">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 20px; height: 20px;">
<dxe:ASPxCheckBox ClientInstanceName="_dx" ID="chkAllDay" runat="server" Checked='<%#(CType(Container, AppointmentFormTemplateContainer)).Appointment.AllDay%>'>
</dxe:ASPxCheckBox>
</td>
<td style="padding-left: 2px;">
<dxe:ASPxLabel ID="lblAllDay" runat="server" Text="All day event" AssociatedControlID="chkAllDay" />
</td>
</tr>
</table>
</td>
</tr>
<tr>
<%
If CanShowReminders Then
%>
<td class="dxscSingleCell">
<%
Else
%>
<td class="dxscDoubleCell" colspan="2">
<%
End If
%>
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell">
<dxe:ASPxLabel ID="lblResource" runat="server" AssociatedControlID="edtResource" Text="Resource:">
</dxe:ASPxLabel>
</td>
<td class="dxscControlCell">
<%
If ResourceSharing Then
%>
<dxe:ASPxDropDownEdit id="ddResource" runat="server" Width="100%" ClientInstanceName="ddResource" Enabled='<%#(CType(Container, AppointmentFormTemplateContainer)).CanEditResource%>' AllowUserInput="false">
<DropDownWindowTemplate>
<dxe:ASPxListBox id="edtMultiResource" runat="server" width="100%" SelectionMode="CheckColumn" DataSource='<%#ResourceDataSource%>' Border-BorderWidth="0"/>
</DropDownWindowTemplate>
</dxe:ASPxDropDownEdit>
<%
Else
%>
<dxe:ASPxComboBox ClientInstanceName="_dx" ID="edtResource" runat="server" Width="100%" DataSource='<%#ResourceDataSource%> ' Enabled='<%#(CType(Container, AppointmentFormTemplateContainer)).CanEditResource%>' />
<%
End If
%>
</td>
</tr>
</table>
</td>
<%
If CanShowReminders Then
%>
<td class="dxscSingleCell">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell" style="padding-left: 22px;">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 20px; height: 20px;">
<dxe:ASPxCheckBox ID="chkReminder" runat="server">
</dxe:ASPxCheckBox>
</td>
<td style="padding-left: 2px;">
<dxe:ASPxLabel ID="lblReminder" runat="server" Text="Reminder" AssociatedControlID="chkReminder" />
</td>
</tr>
</table>
</td>
<td class="dxscControlCell" style="padding-left: 3px">
<dxe:ASPxComboBox ID="cbReminder" runat="server" Width="100%" DataSource='<%#(CType(Container, AppointmentFormTemplateContainer)).ReminderDataSource%>' />
</td>
</tr>
</table>
</td>
<%
End If
%>
</tr>
<tr>
<td class="dxscDoubleCell" colspan="2" style="height: 90px;">
<dxe:ASPxMemo ClientInstanceName="_dx" ID="tbDescription" runat="server" Width="100%" Rows="6" Text='<%#(CType(Container, AppointmentFormTemplateContainer)).Appointment.Description%>' />
</td>
</tr>
</table>
<dxsc:AppointmentRecurrenceForm ID="AppointmentRecurrenceForm1" runat="server"
IsRecurring='<%#(CType(Container, AppointmentFormTemplateContainer)).Appointment.IsRecurring%>'
DayNumber='<%#(CType(Container, AppointmentFormTemplateContainer)).RecurrenceDayNumber%>'
End='<%#(CType(Container, AppointmentFormTemplateContainer)).RecurrenceEnd%>'
Month='<%#(CType(Container, AppointmentFormTemplateContainer)).RecurrenceMonth%>'
OccurrenceCount='<%#(CType(Container, AppointmentFormTemplateContainer)).RecurrenceOccurrenceCount%>'
Periodicity='<%#(CType(Container, AppointmentFormTemplateContainer)).RecurrencePeriodicity%>'
RecurrenceRange='<%#(CType(Container, AppointmentFormTemplateContainer)).RecurrenceRange%>'
Start='<%#(CType(Container, AppointmentFormTemplateContainer)).RecurrenceStart%>'
WeekDays='<%#(CType(Container, AppointmentFormTemplateContainer)).RecurrenceWeekDays%>'
WeekOfMonth='<%#(CType(Container, AppointmentFormTemplateContainer)).RecurrenceWeekOfMonth%>'
RecurrenceType='<%#(CType(Container, AppointmentFormTemplateContainer)).RecurrenceType%>'
IsFormRecreated='<%#(CType(Container, AppointmentFormTemplateContainer)).IsFormRecreated%>' >
</dxsc:AppointmentRecurrenceForm>
<table cellpadding="0" cellspacing="0" style="width: 100%; height: 35px;">
<tr>
<td style="width: 100%; height: 100%;" align="center">
<table style="height: 100%;">
<tr>
<td>
<dxe:ASPxButton runat="server" ID="btnOk" Text="OK" UseSubmitBehavior="false" AutoPostBack="false"
EnableViewState="false" Width="91px" EnableClientSideAPI="true"/>
</td>
<td>
<dxe:ASPxButton runat="server" ID="btnCancel" Text="Cancel" UseSubmitBehavior="false" AutoPostBack="false" EnableViewState="false"
Width="91px" CausesValidation="False" EnableClientSideAPI="true" />
</td>
<td>
<dxe:ASPxButton runat="server" ID="btnDelete" Text="Delete" UseSubmitBehavior="false"
AutoPostBack="false" EnableViewState="false" Width="91px"
Enabled='<%#(CType(Container, AppointmentFormTemplateContainer)).CanDeleteAppointment%>'
CausesValidation="False" />
</td>
</tr>
</table>
</td>
</tr>
</table>
<table cellpadding="0" cellspacing="0" style="width: 100%;">
<tr>
<td style="width: 100%;" align="left">
<dxsc:ASPxSchedulerStatusInfo runat="server" ID="schedulerStatusInfo" Priority="1" MasterControlId='<%#(CType(Container, DevExpress.Web.ASPxScheduler.AppointmentFormTemplateContainer)).ControlId%>' />
</td>
</tr>
</table>
<script id="dxss_ASPxSchedulerAppoinmentForm" type="text/javascript">
ASPxAppointmentForm = _aspxCreateClass(ASPxClientFormBase, {
Initialize: function () {
this.controls.edtStartDate.Validation.AddHandler(_aspxCreateDelegate(this.OnEdtStartDateValidate, this));
this.controls.edtEndDate.Validation.AddHandler(_aspxCreateDelegate(this.OnEdtEndDateValidate, this));
this.controls.edtStartDate.ValueChanged.AddHandler(_aspxCreateDelegate(this.OnUpdateStartEndValue, this));
this.controls.edtEndDate.ValueChanged.AddHandler(_aspxCreateDelegate(this.OnUpdateStartEndValue, this));
if (this.controls.chkReminder)
this.controls.chkReminder.CheckedChanged.AddHandler(_aspxCreateDelegate(this.OnChkReminderCheckedChanged, this));
if (this.controls.edtMultiResource)
this.controls.edtMultiResource.SelectedIndexChanged.AddHandler(_aspxCreateDelegate(this.OnEdtMultiResourceSelectedIndexChanged, this));
},
OnEdtMultiResourceSelectedIndexChanged: function (s, e) {
var resourceNames = new Array();
var items = s.GetSelectedItems();
var count = items.length;
if (count > 0) {
for (var i = 0; i < count; i++)
resourceNames.push(items[i].text);
}
else
resourceNames.push(ddResource.cp_Caption_ResourceNone);
ddResource.SetValue(resourceNames.join(', '));
},
OnEdtStartDateValidate: function (s, e) {
if (!e.isValid)
return;
var startDate = this.controls.edtStartDate.GetDate();
var endDate = this.controls.edtEndDate.GetDate();
e.isValid = startDate == null || endDate == null || startDate < endDate;
e.errorText = "The Start Date must precede the End Date.";
},
OnEdtEndDateValidate: function (s, e) {
if (!e.isValid)
return;
var startDate = this.controls.edtStartDate.GetDate();
var endDate = this.controls.edtEndDate.GetDate();
e.isValid = startDate == null || endDate == null || startDate < endDate;
e.errorText = "The Start Date must precede the End Date.";
},
OnUpdateStartEndValue: function (s, e) {
var isValid = ASPxClientEdit.ValidateEditorsInContainer(null);
this.controls.btnOk.SetEnabled(isValid);
},
OnChkReminderCheckedChanged: function (s, e) {
var isReminderEnabled = this.controls.chkReminder.GetValue();
if (isReminderEnabled)
this.controls.cbReminder.SetSelectedIndex(3);
else
this.controls.cbReminder.SetSelectedIndex(-1);
this.controls.cbReminder.SetEnabled(isReminderEnabled);
}
});
</script>
@@ -0,0 +1,249 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class AppointmentForm
'''<summary>
'''lblSubject control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblSubject As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''tbSubject control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents tbSubject As Global.DevExpress.Web.ASPxTextBox
'''<summary>
'''lblLocation control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblLocation As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''tbLocation control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents tbLocation As Global.DevExpress.Web.ASPxTextBox
'''<summary>
'''lblLabel control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblLabel As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''edtLabel control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents edtLabel As Global.DevExpress.Web.ASPxComboBox
'''<summary>
'''lblStartDate control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblStartDate As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''edtStartDate control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents edtStartDate As Global.DevExpress.Web.ASPxDateEdit
'''<summary>
'''lblEndDate control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblEndDate As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''edtEndDate control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents edtEndDate As Global.DevExpress.Web.ASPxDateEdit
'''<summary>
'''lblStatus control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblStatus As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''edtStatus control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents edtStatus As Global.DevExpress.Web.ASPxComboBox
'''<summary>
'''chkAllDay control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents chkAllDay As Global.DevExpress.Web.ASPxCheckBox
'''<summary>
'''lblAllDay control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblAllDay As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''lblResource control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblResource As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''ddResource control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents ddResource As Global.DevExpress.Web.ASPxDropDownEdit
'''<summary>
'''edtResource control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents edtResource As Global.DevExpress.Web.ASPxComboBox
'''<summary>
'''chkReminder control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents chkReminder As Global.DevExpress.Web.ASPxCheckBox
'''<summary>
'''lblReminder control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblReminder As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''cbReminder control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents cbReminder As Global.DevExpress.Web.ASPxComboBox
'''<summary>
'''tbDescription control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents tbDescription As Global.DevExpress.Web.ASPxMemo
'''<summary>
'''AppointmentRecurrenceForm1 control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents AppointmentRecurrenceForm1 As Global.DevExpress.Web.ASPxScheduler.Controls.AppointmentRecurrenceForm
'''<summary>
'''btnOk control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnOk As Global.DevExpress.Web.ASPxButton
'''<summary>
'''btnCancel control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnCancel As Global.DevExpress.Web.ASPxButton
'''<summary>
'''btnDelete control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnDelete As Global.DevExpress.Web.ASPxButton
'''<summary>
'''schedulerStatusInfo control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents schedulerStatusInfo As Global.DevExpress.Web.ASPxScheduler.Controls.ASPxSchedulerStatusInfo
End Class
@@ -0,0 +1,172 @@
'
'{************************************************************************************}
'{ }
'{ DO NOT MODIFY THIS FILE! }
'{ }
'{ It will be overwritten without prompting when a new version becomes }
'{ available. All your changes will be lost. }
'{ }
'{ This file contains the default template and is required for the form }
'{ rendering. Improper modifications may result in incorrect behavior of }
'{ the appointment form. }
'{ }
'{ In order to create and use your own custom template, perform the following }
'{ steps: }
'{ 1. Save a copy of this file with a different name in another location. }
'{ 2. Specify the file location as the 'OptionsForms.AppointmentFormTemplateUrl'}
'{ property of the ASPxScheduler control. }
'{ 3. If you need custom fields to be displayed and processed, you should }
'{ accomplish steps 4-9; otherwise, go to step 10. }
'{ 4. Create a class, derived from the AppointmentFormTemplateContainer, }
'{ containing custom properties. This class definition can be located }
'{ within a class file in the App_Code folder. }
'{ 5. Replace AppointmentFormTemplateContainer references in the template }
'{ page with the name of the class you've created in step 4. }
'{ 6. Handle the AppointmentFormShowing event to create an instance of the }
'{ template container class, defined in step 4, and specify it as the }
'{ destination container instead of the default one. }
'{ 7. Define a class, which inherits from the }
'{ DevExpress.Web.ASPxScheduler.Internal.AppointmentFormController. }
'{ This class provides data exchange between the form and the appointment. }
'{ You should override ApplyCustomFieldsValues() method of the base class. }
'{ 8. Define a class, which inherits from the }
'{ DevExpress.Web.ASPxScheduler.Internal.AppointmentFormSaveCallbackCommand. }
'{ This class creates an instance of the AppointmentFormController inheritor }
'{ (defined in step 7) via the CreateAppointmentFormController method and }
'{ overrides the AssignControllerValues method of the base class to collect }
'{ user data from the form's editors. }
'{ 9. Handle the BeforeExecuteCallbackCommand event. The event handler code }
'{ should create an instance of the class defined in step 8, and specify it }
'{ as the destination command instead of the default one. }
'{ 10. Modify the overall appearance of the page and its layout. }
'{ }
'{************************************************************************************}
'
Imports Microsoft.VisualBasic
Imports System
Imports System.Web.UI
Imports DevExpress.XtraScheduler
Imports DevExpress.Web
Imports DevExpress.Web.ASPxScheduler
Imports DevExpress.Web.ASPxScheduler.Internal
Imports System.Collections
Imports System.Collections.Generic
Imports DevExpress.XtraScheduler.Localization
Partial Public Class AppointmentForm
Inherits SchedulerFormControl
Public Overrides ReadOnly Property ClassName() As String
Get
Return "ASPxAppointmentForm"
End Get
End Property
Public ReadOnly Property CanShowReminders() As Boolean
Get
Return (CType(Parent, AppointmentFormTemplateContainer)).Control.Storage.EnableReminders
End Get
End Property
Public ReadOnly Property ResourceSharing() As Boolean
Get
Return (CType(Parent, AppointmentFormTemplateContainer)).Control.Storage.ResourceSharing
End Get
End Property
Public ReadOnly Property ResourceDataSource() As IEnumerable
Get
Return (CType(Parent, AppointmentFormTemplateContainer)).ResourceDataSource
End Get
End Property
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
'PrepareChildControls();
tbSubject.Focus()
End Sub
Public Overrides Sub DataBind()
MyBase.DataBind()
Dim container As AppointmentFormTemplateContainer = CType(Parent, AppointmentFormTemplateContainer)
Dim apt As Appointment = container.Appointment
edtLabel.SelectedIndex = apt.LabelId
edtStatus.SelectedIndex = apt.StatusId
PopulateResourceEditors(apt, container)
AppointmentRecurrenceForm1.Visible = container.ShouldShowRecurrence
If container.Appointment.HasReminder Then
cbReminder.Value = container.Appointment.Reminder.TimeBeforeStart.ToString()
chkReminder.Checked = True
Else
cbReminder.ClientEnabled = False
End If
btnOk.ClientSideEvents.Click = container.SaveHandler
btnCancel.ClientSideEvents.Click = container.CancelHandler
btnDelete.ClientSideEvents.Click = container.DeleteHandler
'btnDelete.Enabled = !container.IsNewAppointment;
End Sub
Private Sub PopulateResourceEditors(ByVal apt As Appointment, ByVal container As AppointmentFormTemplateContainer)
If ResourceSharing Then
Dim edtMultiResource As ASPxListBox = TryCast(ddResource.FindControl("edtMultiResource"), ASPxListBox)
If edtMultiResource Is Nothing Then
Return
End If
SetListBoxSelectedValues(edtMultiResource, apt.ResourceIds)
Dim multiResourceString As List(Of String) = GetListBoxSeletedItemsText(edtMultiResource)
Dim stringResourceNone As String = SchedulerLocalizer.GetString(SchedulerStringId.Caption_ResourceNone)
ddResource.Value = stringResourceNone
If multiResourceString.Count > 0 Then
ddResource.Value = String.Join(", ", multiResourceString.ToArray())
End If
ddResource.JSProperties.Add("cp_Caption_ResourceNone", stringResourceNone)
Else
If (Not Object.Equals(apt.ResourceId, Resource.Empty.Id)) Then
edtResource.Value = apt.ResourceId.ToString()
Else
edtResource.Value = SchedulerIdHelper.EmptyResourceId
End If
End If
End Sub
Private Function GetListBoxSeletedItemsText(ByVal listBox As ASPxListBox) As List(Of String)
Dim result As New List(Of String)()
For Each editItem As ListEditItem In listBox.Items
If editItem.Selected Then
result.Add(editItem.Text)
End If
Next editItem
Return result
End Function
Private Sub SetListBoxSelectedValues(ByVal listBox As ASPxListBox, ByVal values As IEnumerable)
listBox.Value = Nothing
For Each value As Object In values
Dim item As ListEditItem = listBox.Items.FindByValue(value.ToString())
If item IsNot Nothing Then
item.Selected = True
End If
Next value
End Sub
Protected Overrides Sub PrepareChildControls()
Dim container As AppointmentFormTemplateContainer = CType(Parent, AppointmentFormTemplateContainer)
Dim control As ASPxScheduler = container.Control
AppointmentRecurrenceForm1.EditorsInfo = New EditorsInfo(control, control.Styles.FormEditors, control.Images.FormEditors, control.Styles.Buttons)
MyBase.PrepareChildControls()
End Sub
Protected Overrides Function GetChildEditors() As ASPxEditBase()
Dim edits() As ASPxEditBase = { lblSubject, tbSubject, lblLocation, tbLocation, lblLabel, edtLabel, lblStartDate, edtStartDate, lblEndDate, edtEndDate, lblStatus, edtStatus, lblAllDay, chkAllDay, lblResource, edtResource, tbDescription, cbReminder, ddResource, chkReminder, GetMultiResourceEditor() }
Return edits
End Function
Private Function GetMultiResourceEditor() As ASPxEditBase
If ddResource IsNot Nothing Then
Return TryCast(ddResource.FindControl("edtMultiResource"), ASPxEditBase)
End If
Return Nothing
End Function
Protected Overrides Function GetChildButtons() As ASPxButton()
Dim buttons() As ASPxButton = { btnOk, btnCancel, btnDelete }
Return buttons
End Function
End Class
@@ -0,0 +1,296 @@
<%--
{************************************************************************************}
{ }
{ DO NOT MODIFY THIS FILE! }
{ }
{ It will be overwritten without prompting when a new version becomes }
{ available. All your changes will be lost. }
{ }
{ This file contains the default template and is required for the form }
{ rendering. Improper modifications may result in incorrect behavior of }
{ the appointment form. }
{ }
{ In order to create and use your own custom template, perform the following }
{ steps: }
{ 1. Save a copy of this file with a different name in another location. }
{ 2. Specify the file location as the 'OptionsForms.AppointmentFormTemplateUrl'}
{ property of the ASPxScheduler control. }
{ 3. If you need custom fields to be displayed and processed, you should }
{ accomplish steps 4-9; otherwise, go to step 10. }
{ 4. Create a class, derived from the AppointmentFormTemplateContainer, }
{ containing custom properties. This class definition can be located }
{ within a class file in the App_Code folder. }
{ 5. Replace AppointmentFormTemplateContainer references in the template }
{ page with the name of the class you've created in step 4. }
{ 6. Handle the AppointmentFormShowing event to create an instance of the }
{ template container class, defined in step 4, and specify it as the }
{ destination container instead of the default one. }
{ 7. Define a class, which inherits from the }
{ DevExpress.Web.ASPxScheduler.Internal.AppointmentFormController. }
{ This class provides data exchange between the form and the appointment. }
{ You should override ApplyCustomFieldsValues() method of the base class. }
{ 8. Define a class, which inherits from the }
{ DevExpress.Web.ASPxScheduler.Internal.AppointmentFormSaveCallbackCommand. }
{ This class creates an instance of the AppointmentFormController inheritor }
{ (defined in step 7) via the CreateAppointmentFormController method and }
{ overrides the AssignControllerValues method of the base class to collect }
{ user data from the form's editors. }
{ 9. Handle the BeforeExecuteCallbackCommand event. The event handler code }
{ should create an instance of the class defined in step 8, and specify it }
{ as the destination command instead of the default one. }
{ 10. Modify the overall appearance of the page and its layout. }
{ }
{************************************************************************************}
--%>
<%@ Control Language="vb" AutoEventWireup="true" Inherits="AppointmentFormEx" Codebehind="AppointmentFormEx.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web" TagPrefix="dxe" %>
<%@ Register Assembly="DevExpress.Web.ASPxScheduler.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxScheduler.Controls" TagPrefix="dxsc" %>
<%@ Register Assembly="DevExpress.Web.ASPxScheduler.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxScheduler" TagPrefix="dxwschs" %>
<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web" TagPrefix="dxcp" %>
<table class="dxscAppointmentForm" cellpadding="0" cellspacing="0" style="width: 100%; height: 230px;">
<tr>
<td class="dxscDoubleCell" colspan="2">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell">
<dxe:ASPxLabel ID="lblSubject" runat="server" AssociatedControlID="tbSubject" Text="Subject:">
</dxe:ASPxLabel>
</td>
<td class="dxscControlCell">
<dxe:ASPxTextBox ClientInstanceName="_dx" ID="tbSubject" runat="server" Width="100%" Text='<%#(CType(Container, AppointmentFormTemplateContainer)).Appointment.Subject%>' />
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="dxscSingleCell">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell">
<dxe:ASPxLabel ID="lblLocation" runat="server" AssociatedControlID="tbLocation" Text="Location:">
</dxe:ASPxLabel>
</td>
<td class="dxscControlCell">
<dxe:ASPxTextBox ClientInstanceName="_dx" ID="tbLocation" runat="server" Width="100%" Text='<%#(CType(Container, AppointmentFormTemplateContainer)).Appointment.Location%>' />
</td>
</tr>
</table>
</td>
<td class="dxscSingleCell">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell" style="padding-left: 25px;">
<dxe:ASPxLabel ID="lblLabel" runat="server" AssociatedControlID="edtLabel" Text="Label:">
</dxe:ASPxLabel>
</td>
<td class="dxscControlCell">
<dxe:ASPxComboBox ClientInstanceName="_dx" ID="edtLabel" runat="server" Width="100%" DataSource='<%#(CType(Container, AppointmentFormTemplateContainer)).LabelDataSource%>' />
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="dxscSingleCell">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell">
<dxe:ASPxLabel ID="lblStartDate" runat="server" AssociatedControlID="edtStartDate" Text="Start time:" Wrap="false">
</dxe:ASPxLabel>
</td>
<td class="dxscControlCell">
<dxe:ASPxDateEdit ClientInstanceName="_dx" ID="edtStartDate" runat="server" Width="100%" Date='<%#(CType(Container, AppointmentFormTemplateContainer)).Start%>' EditFormat="DateTime" DateOnError="Undo" AllowNull="false"/>
</td>
</tr>
</table>
</td>
<td class="dxscSingleCell">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell" style="padding-left: 25px;">
<dxe:ASPxLabel runat="server" ID="lblEndDate" Text="End time:" Wrap="false" AssociatedControlID="edtEndDate"/>
</td>
<td class="dxscControlCell">
<dxe:ASPxDateEdit id="edtEndDate" runat="server" Date='<%#(CType(Container, AppointmentFormTemplateContainer)).End%>'
EditFormat="DateTime" Width="100%" DateOnError="Undo" AllowNull="false">
</dxe:ASPxDateEdit>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="dxscSingleCell">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell">
<dxe:ASPxLabel ID="lblStatus" runat="server" AssociatedControlID="edtStatus" Text="Show time as:" Wrap="false">
</dxe:ASPxLabel>
</td>
<td class="dxscControlCell">
<dxe:ASPxComboBox ClientInstanceName="_dx" ID="edtStatus" runat="server" Width="100%" DataSource='<%#(CType(Container, AppointmentFormTemplateContainer)).StatusDataSource%>' />
</td>
</tr>
</table>
</td>
<td class="dxscSingleCell" style="padding-left: 22px;">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 20px; height: 20px;">
<dxe:ASPxCheckBox ClientInstanceName="_dx" ID="chkAllDay" runat="server" Checked='<%#(CType(Container, AppointmentFormTemplateContainer)).Appointment.AllDay%>' />
</td>
<td style="padding-left: 2px;">
<dxe:ASPxLabel ID="lblAllDay" runat="server" Text="All day event" AssociatedControlID="chkAllDay" />
</td>
</tr>
</table>
</td>
</tr>
<tr>
<%
If CanShowReminders Then
%>
<td class="dxscSingleCell">
<%
Else
%>
<td class="dxscDoubleCell" colspan="2">
<%
End If
%>
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell">
<dxe:ASPxLabel ID="lblResource" runat="server" AssociatedControlID="edtResource" Text="Resource:">
</dxe:ASPxLabel>
</td>
<td class="dxscControlCell">
<%
If ResourceSharing Then
%>
<dxe:ASPxDropDownEdit id="ddResource" runat="server" Width="100%" ClientInstanceName="ddResource" Enabled='<%#(CType(Container, AppointmentFormTemplateContainer)).CanEditResource%>' AllowUserInput="false">
<DropDownWindowTemplate>
<dxe:ASPxListBox id="edtMultiResource" runat="server" width="100%" SelectionMode="CheckColumn" DataSource='<%#ResourceDataSource%>' Border-BorderWidth="0">
<ClientSideEvents SelectedIndexChanged="function(s, e) {
var resourceNames = new Array();
var items = s.GetSelectedItems();
var count = items.length;
if (count > 0) {
for(var i=0; i<count; i++)
resourceNames.push(items[i].text);
}
else
resourceNames.push(ddResource.cp_Caption_ResourceNone);
ddResource.SetValue(resourceNames.join(', '));
}"></ClientSideEvents>
</dxe:ASPxListBox>
</DropDownWindowTemplate>
</dxe:ASPxDropDownEdit>
<%
Else
%>
<dxe:ASPxComboBox ClientInstanceName="_dx" ID="edtResource" runat="server" Width="100%" DataSource='<%#ResourceDataSource%> ' Enabled='<%#(CType(Container, AppointmentFormTemplateContainer)).CanEditResource%>' />
<%
End If
%>
</td>
</tr>
</table>
</td>
<%
If CanShowReminders Then
%>
<td class="dxscSingleCell">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td class="dxscLabelCell" style="padding-left: 22px;">
<table class="dxscLabelControlPair" cellpadding="0" cellspacing="0">
<tr>
<td style="width: 20px; height: 20px;">
<dxe:ASPxCheckBox ClientInstanceName="_dx" ID="chkReminder" runat="server">
<ClientSideEvents CheckedChanged="function(s, e) { OnChkReminderCheckedChanged(s, e); }" />
</dxe:ASPxCheckBox>
</td>
<td style="padding-left: 2px;">
<dxe:ASPxLabel ID="lblReminder" runat="server" Text="Reminder" AssociatedControlID="chkReminder" />
</td>
</tr>
</table>
</td>
<td class="dxscControlCell" style="padding-left: 3px">
<dxe:ASPxComboBox ID="cbReminder" ClientInstanceName="_dxAppointmentForm_cbReminder" runat="server" Width="100%" DataSource='<%#(CType(Container, AppointmentFormTemplateContainer)).ReminderDataSource%>' />
</td>
</tr>
</table>
</td>
<%
End If
%>
</tr>
<tr>
<td class="dxscDoubleCell" colspan="2" style="height: 90px;">
<dxe:ASPxMemo ClientInstanceName="_dx" ID="tbDescription" runat="server" Width="100%" Rows="6" Text='<%#(CType(Container, AppointmentFormTemplateContainer)).Appointment.Description%>' />
</td>
</tr>
</table>
<table>
<tr>
<td class="dxscDoubleCell" colspan="2">
<dxe:ASPxCheckBox ID="chkRecurrence" runat="server" Text="Recurrence" Checked='<%#(CType(Container, AppointmentFormTemplateContainer)).Appointment.IsRecurring%>'>
<ClientSideEvents CheckedChanged="function(s,e) { if (s.GetChecked()) { if (RecurrencePanel.mainElement.innerHTML.replace(/^\s*(\b.*\b|)\s*$/, '') == '') RecurrencePanel.PerformCallback(); else RecurrencePanel.SetVisible(true); } else RecurrencePanel.SetVisible(false); }"
/>
</dxe:ASPxCheckBox>
<dxcp:ASPxCallbackPanel ID="RecurrencePanel" runat="server" Width="100%" ClientInstanceName="RecurrencePanel"
OnCallback="OnCallback">
</dxcp:ASPxCallbackPanel>
</td>
</tr>
</table>
<table cellpadding="0" cellspacing="0" style="width: 100%; height: 35px;">
<tr>
<td style="width: 100%; height: 100%;" align="center">
<table style="height: 100%;">
<tr>
<td>
<dxe:ASPxButton runat="server" ClientInstanceName="_dx" ID="btnOk" Text="OK" UseSubmitBehavior="false" AutoPostBack="false"
EnableViewState="false" Width="91px"/>
</td>
<td>
<dxe:ASPxButton runat="server" ClientInstanceName="_dx" ID="btnCancel" Text="Cancel" UseSubmitBehavior="false" AutoPostBack="false" EnableViewState="false"
Width="91px" CausesValidation="False" />
</td>
<td>
<dxe:ASPxButton runat="server" ClientInstanceName="_dx" ID="btnDelete" Text="Delete" UseSubmitBehavior="false"
AutoPostBack="false" EnableViewState="false" Width="91px"
Enabled='<%#(CType(Container, AppointmentFormTemplateContainer)).CanDeleteAppointment%>'
CausesValidation="False" />
</td>
</tr>
</table>
</td>
</tr>
</table>
<table cellpadding="0" cellspacing="0" style="width: 100%;">
<tr>
<td style="width: 100%;" align="left">
<dxsc:ASPxSchedulerStatusInfo runat="server" ID="schedulerStatusInfo" Priority="1" MasterControlId='<%#(CType(Container, DevExpress.Web.ASPxScheduler.AppointmentFormTemplateContainer)).ControlId%>' />
</td>
</tr>
</table>
<script id="dxss_ASPxSchedulerAppoinmentForm" type="text/javascript">
function OnChkReminderCheckedChanged(s, e) {
var isReminderEnabled = s.GetValue();
if (isReminderEnabled)
_dxAppointmentForm_cbReminder.SetSelectedIndex(3);
else
_dxAppointmentForm_cbReminder.SetSelectedIndex(-1);
_dxAppointmentForm_cbReminder.SetEnabled(isReminderEnabled);
}
</script>
@@ -0,0 +1,258 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class AppointmentFormEx
'''<summary>
'''lblSubject control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblSubject As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''tbSubject control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents tbSubject As Global.DevExpress.Web.ASPxTextBox
'''<summary>
'''lblLocation control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblLocation As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''tbLocation control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents tbLocation As Global.DevExpress.Web.ASPxTextBox
'''<summary>
'''lblLabel control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblLabel As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''edtLabel control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents edtLabel As Global.DevExpress.Web.ASPxComboBox
'''<summary>
'''lblStartDate control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblStartDate As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''edtStartDate control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents edtStartDate As Global.DevExpress.Web.ASPxDateEdit
'''<summary>
'''lblEndDate control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblEndDate As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''edtEndDate control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents edtEndDate As Global.DevExpress.Web.ASPxDateEdit
'''<summary>
'''lblStatus control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblStatus As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''edtStatus control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents edtStatus As Global.DevExpress.Web.ASPxComboBox
'''<summary>
'''chkAllDay control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents chkAllDay As Global.DevExpress.Web.ASPxCheckBox
'''<summary>
'''lblAllDay control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblAllDay As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''lblResource control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblResource As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''ddResource control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents ddResource As Global.DevExpress.Web.ASPxDropDownEdit
'''<summary>
'''edtResource control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents edtResource As Global.DevExpress.Web.ASPxComboBox
'''<summary>
'''chkReminder control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents chkReminder As Global.DevExpress.Web.ASPxCheckBox
'''<summary>
'''lblReminder control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblReminder As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''cbReminder control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents cbReminder As Global.DevExpress.Web.ASPxComboBox
'''<summary>
'''tbDescription control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents tbDescription As Global.DevExpress.Web.ASPxMemo
'''<summary>
'''chkRecurrence control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents chkRecurrence As Global.DevExpress.Web.ASPxCheckBox
'''<summary>
'''RecurrencePanel control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents RecurrencePanel As Global.DevExpress.Web.ASPxCallbackPanel
'''<summary>
'''btnOk control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnOk As Global.DevExpress.Web.ASPxButton
'''<summary>
'''btnCancel control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnCancel As Global.DevExpress.Web.ASPxButton
'''<summary>
'''btnDelete control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnDelete As Global.DevExpress.Web.ASPxButton
'''<summary>
'''schedulerStatusInfo control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents schedulerStatusInfo As Global.DevExpress.Web.ASPxScheduler.Controls.ASPxSchedulerStatusInfo
End Class
@@ -0,0 +1,192 @@
'
'{************************************************************************************}
'{ }
'{ DO NOT MODIFY THIS FILE! }
'{ }
'{ It will be overwritten without prompting when a new version becomes }
'{ available. All your changes will be lost. }
'{ }
'{ This file contains the default template and is required for the form }
'{ rendering. Improper modifications may result in incorrect behavior of }
'{ the appointment form. }
'{ }
'{ In order to create and use your own custom template, perform the following }
'{ steps: }
'{ 1. Save a copy of this file with a different name in another location. }
'{ 2. Specify the file location as the 'OptionsForms.AppointmentFormTemplateUrl'}
'{ property of the ASPxScheduler control. }
'{ 3. If you need custom fields to be displayed and processed, you should }
'{ accomplish steps 4-9; otherwise, go to step 10. }
'{ 4. Create a class, derived from the AppointmentFormTemplateContainer, }
'{ containing custom properties. This class definition can be located }
'{ within a class file in the App_Code folder. }
'{ 5. Replace AppointmentFormTemplateContainer references in the template }
'{ page with the name of the class you've created in step 4. }
'{ 6. Handle the AppointmentFormShowing event to create an instance of the }
'{ template container class, defined in step 4, and specify it as the }
'{ destination container instead of the default one. }
'{ 7. Define a class, which inherits from the }
'{ DevExpress.Web.ASPxScheduler.Internal.AppointmentFormController. }
'{ This class provides data exchange between the form and the appointment. }
'{ You should override ApplyCustomFieldsValues() method of the base class. }
'{ 8. Define a class, which inherits from the }
'{ DevExpress.Web.ASPxScheduler.Internal.AppointmentFormSaveCallbackCommand. }
'{ This class creates an instance of the AppointmentFormController inheritor }
'{ (defined in step 7) via the CreateAppointmentFormController method and }
'{ overrides the AssignControllerValues method of the base class to collect }
'{ user data from the form's editors. }
'{ 9. Handle the BeforeExecuteCallbackCommand event. The event handler code }
'{ should create an instance of the class defined in step 8, and specify it }
'{ as the destination command instead of the default one. }
'{ 10. Modify the overall appearance of the page and its layout. }
'{ }
'{************************************************************************************}
'
Imports Microsoft.VisualBasic
Imports System
Imports System.Web.UI
Imports DevExpress.XtraScheduler
Imports DevExpress.Web
Imports DevExpress.Web.ASPxScheduler
Imports DevExpress.Web.ASPxScheduler.Internal
Imports System.Collections
Imports System.Collections.Generic
Imports DevExpress.XtraScheduler.Localization
Imports DevExpress.Web.ASPxScheduler.Controls
Partial Public Class AppointmentFormEx
Inherits SchedulerFormControl
Private recurrenceControl_Renamed As AppointmentRecurrenceControl
Public ReadOnly Property CanShowReminders() As Boolean
Get
Return (CType(Parent, AppointmentFormTemplateContainer)).Control.Storage.EnableReminders
End Get
End Property
Public ReadOnly Property ResourceSharing() As Boolean
Get
Return (CType(Parent, AppointmentFormTemplateContainer)).Control.Storage.ResourceSharing
End Get
End Property
Public ReadOnly Property ResourceDataSource() As IEnumerable
Get
Return (CType(Parent, AppointmentFormTemplateContainer)).ResourceDataSource
End Get
End Property
Public ReadOnly Property RecurrenceControl() As AppointmentRecurrenceControl
Get
Return recurrenceControl_Renamed
End Get
End Property
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
RenderRecurrenceControl(False)
'PrepareChildControls();
tbSubject.Focus()
End Sub
Protected Overrides Sub Render(ByVal writer As System.Web.UI.HtmlTextWriter)
Dim container As AppointmentFormTemplateContainer = CType(Parent, AppointmentFormTemplateContainer)
Dim control As ASPxScheduler = container.Control
RecurrenceControl.EditorsInfo = New EditorsInfo(control, control.Styles.FormEditors, control.Images.FormEditors, control.Styles.Buttons)
RecurrenceControl.Visible = chkRecurrence.Checked AndAlso chkRecurrence.Visible
MyBase.Render(writer)
End Sub
Public Overrides Sub DataBind()
MyBase.DataBind()
Dim container As AppointmentFormTemplateContainer = CType(Parent, AppointmentFormTemplateContainer)
Dim apt As Appointment = container.Appointment
edtLabel.SelectedIndex = apt.LabelId
edtStatus.SelectedIndex = apt.StatusId
PopulateResourceEditors(apt, container)
chkRecurrence.Visible = container.ShouldShowRecurrence
'AppointmentRecurrenceForm1.Visible = container.ShouldShowRecurrence;
If container.Appointment.HasReminder Then
cbReminder.Value = container.Appointment.Reminder.TimeBeforeStart.ToString()
chkReminder.Checked = True
Else
cbReminder.ClientEnabled = False
End If
btnOk.ClientSideEvents.Click = container.SaveHandler
btnCancel.ClientSideEvents.Click = container.CancelHandler
btnDelete.ClientSideEvents.Click = container.DeleteHandler
End Sub
Private Sub PopulateResourceEditors(ByVal apt As Appointment, ByVal container As AppointmentFormTemplateContainer)
If ResourceSharing Then
Dim edtMultiResource As ASPxListBox = TryCast(ddResource.FindControl("edtMultiResource"), ASPxListBox)
If edtMultiResource Is Nothing Then
Return
End If
SetListBoxSelectedValues(edtMultiResource, apt.ResourceIds)
Dim multiResourceString As List(Of String) = GetListBoxSeletedItemsText(edtMultiResource)
Dim stringResourceNone As String = SchedulerLocalizer.GetString(SchedulerStringId.Caption_ResourceNone)
ddResource.Value = stringResourceNone
If multiResourceString.Count > 0 Then
ddResource.Value = String.Join(", ", multiResourceString.ToArray())
End If
ddResource.JSProperties.Add("cp_Caption_ResourceNone", stringResourceNone)
Else
If (Not Object.Equals(apt.ResourceId, Resource.Empty.Id)) Then
edtResource.Value = apt.ResourceId.ToString()
Else
edtResource.Value = SchedulerIdHelper.EmptyResourceId
End If
End If
End Sub
Private Function GetListBoxSeletedItemsText(ByVal listBox As ASPxListBox) As List(Of String)
Dim result As New List(Of String)()
For Each editItem As ListEditItem In listBox.Items
If editItem.Selected Then
result.Add(editItem.Text)
End If
Next editItem
Return result
End Function
Private Sub SetListBoxSelectedValues(ByVal listBox As ASPxListBox, ByVal values As IEnumerable)
listBox.Value = Nothing
For Each value As Object In values
Dim item As ListEditItem = listBox.Items.FindByValue(value.ToString())
If item IsNot Nothing Then
item.Selected = True
End If
Next value
End Sub
Protected Overrides Function GetChildEditors() As ASPxEditBase()
Dim edits() As ASPxEditBase = { lblSubject, tbSubject, lblLocation, tbLocation, lblLabel, edtLabel, lblStartDate, edtStartDate, lblEndDate, edtEndDate, lblStatus, edtStatus, lblAllDay, chkAllDay, lblResource, edtResource, tbDescription, cbReminder, ddResource }
Return edits
End Function
Protected Overrides Function GetChildButtons() As ASPxButton()
Dim buttons() As ASPxButton = { btnOk, btnCancel, btnDelete }
Return buttons
End Function
Protected Sub OnCallback(ByVal sender As Object, ByVal e As CallbackEventArgsBase)
RenderRecurrenceControl(True)
End Sub
Protected Sub RenderRecurrenceControl(ByVal isRecurring As Boolean)
If Me.recurrenceControl_Renamed IsNot Nothing Then
Me.recurrenceControl_Renamed.Visible = isRecurring
Return
End If
Dim container As AppointmentFormTemplateContainer = CType(Parent, AppointmentFormTemplateContainer)
Me.recurrenceControl_Renamed = New AppointmentRecurrenceControl()
recurrenceControl_Renamed.ID = "RecurrenceControl1"
recurrenceControl_Renamed.Visible = isRecurring 'container.ShouldShowRecurrence;
recurrenceControl_Renamed.DayNumber = container.RecurrenceDayNumber
recurrenceControl_Renamed.End = container.RecurrenceEnd
recurrenceControl_Renamed.Month = container.RecurrenceMonth
recurrenceControl_Renamed.OccurrenceCount = container.RecurrenceOccurrenceCount
recurrenceControl_Renamed.Periodicity = container.RecurrencePeriodicity
recurrenceControl_Renamed.RecurrenceRange = container.RecurrenceRange
recurrenceControl_Renamed.Start = container.RecurrenceStart
recurrenceControl_Renamed.WeekDays = container.RecurrenceWeekDays
recurrenceControl_Renamed.WeekOfMonth = container.RecurrenceWeekOfMonth
recurrenceControl_Renamed.RecurrenceType = container.RecurrenceType
recurrenceControl_Renamed.IsFormRecreated = container.IsFormRecreated
RecurrencePanel.Controls.Add(recurrenceControl_Renamed)
recurrenceControl_Renamed.EditorsInfo = New EditorsInfo(container.Control, container.Control.Styles.FormEditors, container.Control.Images.FormEditors, container.Control.Styles.Buttons)
End Sub
End Class
@@ -0,0 +1,22 @@
<%@ Control Language="vb" AutoEventWireup="true" Inherits="UserForms_AppointmentToolTip" Codebehind="AppointmentToolTip.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.v15.2" Namespace="DevExpress.Web"
TagPrefix="dxe" %>
<div runat="server" id="buttonDiv">
<dxe:ASPxButton ID="btnShowMenu" runat="server" AutoPostBack="False" AllowFocus="False">
<Border BorderWidth="0px" />
<Paddings Padding="0px" />
<FocusRectPaddings Padding="4px" />
<FocusRectBorder BorderStyle="None" BorderWidth="0px" />
</dxe:ASPxButton>
</div>
<script type="text/javascript" id="dxss_ASPxClientAppointmentToolTip">
ASPxClientAppointmentToolTip = _aspxCreateClass(ASPxClientToolTipBase, {
Initialize: function() {
ASPxClientUtils.AttachEventToElement(this.controls.buttonDiv, "click", _aspxCreateDelegate(this.OnButtonDivClick, this));
},
OnButtonDivClick: function(s,e) {
this.ShowAppointmentMenu(s);
}
});
</script>
@@ -0,0 +1,33 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class UserForms_AppointmentToolTip
'''<summary>
'''buttonDiv control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents buttonDiv As Global.System.Web.UI.HtmlControls.HtmlGenericControl
'''<summary>
'''btnShowMenu control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnShowMenu As Global.DevExpress.Web.ASPxButton
End Class
@@ -0,0 +1,38 @@
Imports Microsoft.VisualBasic
Imports System
Imports System.Data
Imports System.Configuration
Imports System.Collections
Imports System.Web
Imports System.Web.Security
Imports System.Web.UI
Imports System.Web.UI.WebControls
Imports System.Web.UI.WebControls.WebParts
Imports System.Web.UI.HtmlControls
Imports DevExpress.Web.ASPxScheduler
Partial Public Class UserForms_AppointmentToolTip
Inherits ASPxSchedulerToolTipBase
Public Overrides ReadOnly Property ToolTipShowStem() As Boolean
Get
Return False
End Get
End Property
Public Overrides ReadOnly Property ClassName() As String
Get
Return "ASPxClientAppointmentToolTip"
End Get
End Property
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
DevExpress.Web.ASPxWebControl.RegisterBaseScript(Page)
End Sub
Protected Overrides Sub OnLoad(ByVal e As EventArgs)
MyBase.OnLoad(e)
btnShowMenu.Image.Assign(GetSmartTagImage())
End Sub
Protected Overrides Function GetChildControls() As Control()
Dim controls() As Control = { buttonDiv}
Return controls
End Function
End Class
@@ -0,0 +1,73 @@
<%--
{************************************************************************************}
{ }
{ DO NOT MODIFY THIS FILE! }
{ }
{ It will be overwritten without prompting when a new version becomes }
{ available. All your changes will be lost. }
{ }
{ This file contains the default template and is required for the form }
{ rendering. Improper modifications may result in incorrect behavior of }
{ the appointment form. }
{ }
{ In order to create and use your own custom template, perform the following }
{ steps: }
{ 1. Save a copy of this file with a different name in another location. }
{ 2. Specify the file location as the 'OptionsForms.GotoDateFormTemplateUrl' }
{ property of the ASPxScheduler control. }
{ 3. If you need to display and process additional controls, you }
{ should accomplish steps 4-6; otherwise, go to step 7. }
{ 4. Create a class, derived from the GotoDateFormTemplateContainer, }
{ containing additional properties which correspond to your controls. }
{ This class definition can be located within a class file in the App_Code }
{ folder. }
{ 5. Replace GotoDateFormTemplateContainer references in the template page }
{ with the name of the class you've created in step 4. }
{ 6. Handle the GotoDateFormShowing event to create an instance of the }
{ template container class, defined in step 5, and specify it as the }
{ destination container instead of the default one. }
{ 7. Modify the overall appearance of the page and its layout. }
{ }
{************************************************************************************}
--%>
<%@ Control Language="vb" AutoEventWireup="true" Inherits="GotoDateForm" Codebehind="GotoDateForm.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.ASPxScheduler.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxScheduler" TagPrefix="dxwschs" %>
<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web"
TagPrefix="dxe" %>
<table style="width:100%; height:100%">
<tr>
<td>
<dxe:ASPxLabel ID="lblDate" runat="server" Text="Date:" AssociatedControlID="edtDate" />
</td>
<td style="width:100%">
<dxe:ASPxDateEdit ClientInstanceName="_dx" ID="edtDate" runat="server" Width="100%" Date='<%#(CType(Container, GotoDateFormTemplateContainer)).Date%>' />
</td>
</tr>
<tr>
<td>
<span style="white-space: nowrap;">
<dxe:ASPxLabel ID="lblView" runat="server" Text="Show in:" AssociatedControlID="cbView"></dxe:ASPxLabel>
</span>
</td>
<td style="width:100%">
<dxe:ASPxComboBox ClientInstanceName="_dx" ID="cbView" runat="server" Width="100%" DataSource='<%#(CType(Container, GotoDateFormTemplateContainer)).ViewsDataSource%>'></dxe:ASPxComboBox>
</td>
</tr>
<tr>
<td align="center" colspan="2" style="width:100%">
<table>
<tr>
<td>
<dxe:ASPxButton ID="btnOk" ClientInstanceName="_dx" runat="server" Text="OK" UseSubmitBehavior="false" AutoPostBack="false" EnableViewState="false" Width="91px" />
</td>
<td>
<dxe:ASPxButton ID="btnCancel" ClientInstanceName="_dx" runat="server" Text="Cancel" UseSubmitBehavior="false" AutoPostBack="false" EnableViewState="false"
Width="91px" CausesValidation="False" />
</td>
</tr>
</table>
</td>
</tr>
</table>
@@ -0,0 +1,69 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class GotoDateForm
'''<summary>
'''lblDate control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblDate As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''edtDate control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents edtDate As Global.DevExpress.Web.ASPxDateEdit
'''<summary>
'''lblView control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblView As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''cbView control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents cbView As Global.DevExpress.Web.ASPxComboBox
'''<summary>
'''btnOk control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnOk As Global.DevExpress.Web.ASPxButton
'''<summary>
'''btnCancel control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnCancel As Global.DevExpress.Web.ASPxButton
End Class
@@ -0,0 +1,70 @@
'
'{************************************************************************************}
'{ }
'{ DO NOT MODIFY THIS FILE! }
'{ }
'{ It will be overwritten without prompting when a new version becomes }
'{ available. All your changes will be lost. }
'{ }
'{ This file contains the default template and is required for the form }
'{ rendering. Improper modifications may result in incorrect behavior of }
'{ the appointment form. }
'{ }
'{ In order to create and use your own custom template, perform the following }
'{ steps: }
'{ 1. Save a copy of this file with a different name in another location. }
'{ 2. Specify the file location as the 'OptionsForms.GotoDateFormTemplateUrl' }
'{ property of the ASPxScheduler control. }
'{ 3. If you need to display and process additional controls, you }
'{ should accomplish steps 4-6; otherwise, go to step 7. }
'{ 4. Create a class, derived from the GotoDateFormTemplateContainer, }
'{ containing additional properties which correspond to your controls. }
'{ This class definition can be located within a class file in the App_Code }
'{ folder. }
'{ 5. Replace GotoDateFormTemplateContainer references in the template page }
'{ with the name of the class you've created in step 4. }
'{ 6. Handle the GotoDateFormShowing event to create an instance of the }
'{ template container class, defined in step 5, and specify it as the }
'{ destination container instead of the default one. }
'{ 7. Modify the overall appearance of the page and its layout. }
'{ }
'{************************************************************************************}
'
Imports Microsoft.VisualBasic
Imports System
Imports DevExpress.Web
Imports DevExpress.Web.ASPxScheduler
Partial Public Class GotoDateForm
Inherits SchedulerFormControl
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
'PrepareChildControls();
edtDate.Focus()
End Sub
Public Overrides Sub DataBind()
MyBase.DataBind()
Dim container As GotoDateFormTemplateContainer = CType(Parent, GotoDateFormTemplateContainer)
cbView.Value = container.ActiveViewType.ToString()
btnOk.ClientSideEvents.Click = container.ApplyHandler
btnCancel.ClientSideEvents.Click = container.CancelHandler
Dim scheduler As ASPxScheduler = container.Control
Dim actualSchedulerInstanceName As String = scheduler.ClientInstanceName
If String.IsNullOrEmpty(actualSchedulerInstanceName) Then
actualSchedulerInstanceName = scheduler.ClientID
End If
edtDate.ClientSideEvents.LostFocus = String.Format("function(s,e) {{" & ControlChars.CrLf & " var date = s.GetDate();" & ControlChars.CrLf & " if (date == null || date == false) {{" & ControlChars.CrLf & " var selectionInterval = {0}.GetSelectedInterval();" & ControlChars.CrLf & " var startDate = selectionInterval.GetStart();" & ControlChars.CrLf & " s.SetDate(startDate);" & ControlChars.CrLf & " }}" & ControlChars.CrLf & " }}", actualSchedulerInstanceName)
End Sub
Protected Overrides Function GetChildEditors() As ASPxEditBase()
Dim edits() As ASPxEditBase = { lblDate, edtDate, lblView, cbView }
Return edits
End Function
Protected Overrides Function GetChildButtons() As ASPxButton()
Dim buttons() As ASPxButton = { btnOk, btnCancel }
Return buttons
End Function
End Class
@@ -0,0 +1,84 @@
<%--
{************************************************************************************}
{ }
{ DO NOT MODIFY THIS FILE! }
{ }
{ It will be overwritten without prompting when a new version becomes }
{ available. All your changes will be lost. }
{ }
{ This file contains the default template and is required for the appointment }
{ rendering. Improper modifications may result in incorrect appearance of the }
{ appointment. }
{ }
{ In order to create and use your own custom template, perform the following }
{ steps: }
{ 1. Save a copy of this file with a different name in another location. }
{ 2. Add a Register tag in the .aspx page header for each template you use, }
{ as follows: <%@ Register Src="PathToTemplateFile" TagName="NameOfTemplate"}
{ TagPrefix="ShortNameOfTemplate" %> }
{ 3. In the .aspx page find the tags for different scheduler views within }
{ the ASPxScheduler control tag. Insert template tags into the tags }
{ for the views which should be customized. }
{ The template tag should satisfy the following pattern: }
{ <Templates> }
{ <HorizontalAppointmentTemplate> }
{ < ShortNameOfTemplate: NameOfTemplate runat="server"/> }
{ </HorizontalAppointmentTemplate> }
{ </Templates> }
{ where ShortNameOfTemplate, NameOfTemplate are the names of the }
{ registered templates, defined in step 2. }
{************************************************************************************}
--%>
<%@ Control Language="vb" AutoEventWireup="true" Inherits="HorizontalAppointmentTemplate" Codebehind="HorizontalAppointmentTemplate.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.ASPxScheduler.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxScheduler" TagPrefix="dxwschs" %>
<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web" TagPrefix="dxe" %>
<div id="appointmentDiv" runat="server" class='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.AppointmentStyle.CssClass%>'>
<table style="width:100%; height:100%;" cellpadding="0" cellspacing="0">
<tr>
<td runat="server" id="statusContainer" valign="top">
</td>
</tr>
<tr>
<td>
<table cellpadding="0" cellspacing="0" style="width:100%; padding-bottom:2px; padding-top:2px; padding-left:1px; padding-right:1px;">
<tr valign="middle" align="left">
<td>
<asp:Image runat="server" ID="imgStartContinueArrow" Visible='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.StartContinueArrow.Visible%>'></asp:Image>
</td>
<td>
<dxe:ASPxLabel runat="server" EnableViewState="false" EncodeHtml="true" ID="lblStartContinueText" Text='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.StartContinueText.Text%>' Visible='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.StartContinueText.Visible%>'> </dxe:ASPxLabel>
</td>
<td runat="server" id="startTimeClockContainer"> </td>
<td>
<dxe:ASPxLabel runat="server" EnableViewState="false" EncodeHtml="true" ID="lblStartTime" Text='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.StartTimeText.Text%>' Visible='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.StartTimeText.Visible%>' ></dxe:ASPxLabel>
</td>
<td style="width: 100%;" align="center">
<table cellpadding="1" cellspacing="1" style="vertical-align: middle;">
<tr>
<td>
<table id="imageContainer" runat="server" cellpadding="0" cellspacing="0" style="vertical-align: middle;">
</table>
</td>
<td align="center">
<dxe:ASPxLabel runat="server" EnableViewState="false" EncodeHtml="true" ID="lblTitle" Text='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.Title.Text%>'></dxe:ASPxLabel>
</td>
</tr>
</table>
</td>
<td runat="server" id="endTimeClockContainer">
</td>
<td>
<dxe:ASPxLabel runat="server" EnableViewState="false" EncodeHtml="true" ID="lblEndTime" Text='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.EndTimeText.Text%>' Visible='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.EndTimeText.Visible%>' ></dxe:ASPxLabel>
</td>
<td>
<dxe:ASPxLabel runat="server" EnableViewState="false" EncodeHtml="true" ID="lblEndContinueText" Text='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.EndContinueText.Text%>' Visible='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.EndContinueText.Visible%>'></dxe:ASPxLabel>
</td>
<td>
<asp:Image runat="server" ID="imgEndContinueArrow" Visible='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.EndContinueArrow.Visible%>'></asp:Image>
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
@@ -0,0 +1,123 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class HorizontalAppointmentTemplate
'''<summary>
'''appointmentDiv control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents appointmentDiv As Global.System.Web.UI.HtmlControls.HtmlGenericControl
'''<summary>
'''statusContainer control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents statusContainer As Global.System.Web.UI.HtmlControls.HtmlTableCell
'''<summary>
'''imgStartContinueArrow control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents imgStartContinueArrow As Global.System.Web.UI.WebControls.Image
'''<summary>
'''lblStartContinueText control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblStartContinueText As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''startTimeClockContainer control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents startTimeClockContainer As Global.System.Web.UI.HtmlControls.HtmlTableCell
'''<summary>
'''lblStartTime control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblStartTime As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''imageContainer control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents imageContainer As Global.System.Web.UI.HtmlControls.HtmlTable
'''<summary>
'''lblTitle control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblTitle As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''endTimeClockContainer control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents endTimeClockContainer As Global.System.Web.UI.HtmlControls.HtmlTableCell
'''<summary>
'''lblEndTime control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblEndTime As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''lblEndContinueText control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblEndContinueText As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''imgEndContinueArrow control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents imgEndContinueArrow As Global.System.Web.UI.WebControls.Image
End Class
@@ -0,0 +1,87 @@
'
'{************************************************************************************}
'{ }
'{ DO NOT MODIFY THIS FILE! }
'{ }
'{ It will be overwritten without prompting when a new version becomes }
'{ available. All your changes will be lost. }
'{ }
'{ This file contains the default template and is required for the appointment }
'{ rendering. Improper modifications may result in incorrect appearance of the }
'{ appointment. }
'{ }
'{ In order to create and use your own custom template, perform the following }
'{ steps: }
'{ 1. Save a copy of this file with a different name in another location. }
'{ 2. Add a Register tag in the .aspx page header for each template you use, }
'{ as follows: <%@ Register Src="PathToTemplateFile" TagName="NameOfTemplate"}
'{ TagPrefix="ShortNameOfTemplate" %> }
'{ 3. In the .aspx page find the tags for different scheduler views within }
'{ the ASPxScheduler control tag. Insert template tags into the tags }
'{ for the views which should be customized. }
'{ The template tag should satisfy the following pattern: }
'{ <Templates> }
'{ <HorizontalAppointmentTemplate> }
'{ < ShortNameOfTemplate: NameOfTemplate runat="server"/> }
'{ </HorizontalAppointmentTemplate> }
'{ </Templates> }
'{ where ShortNameOfTemplate, NameOfTemplate are the names of the }
'{ registered templates, defined in step 2. }
'{************************************************************************************}
'
Imports Microsoft.VisualBasic
Imports System
Imports System.Web.UI.WebControls
Imports System.Web.UI.HtmlControls
Imports DevExpress.Web.ASPxScheduler
Imports DevExpress.Web.ASPxScheduler.Drawing
Partial Public Class HorizontalAppointmentTemplate
Inherits System.Web.UI.UserControl
Private ReadOnly Property Container() As HorizontalAppointmentTemplateContainer
Get
Return CType(Parent, HorizontalAppointmentTemplateContainer)
End Get
End Property
Private ReadOnly Property Items() As HorizontalAppointmentTemplateItems
Get
Return Container.Items
End Get
End Property
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
appointmentDiv.Style.Value = Items.AppointmentStyle.GetStyleAttributes(Page).Value
lblTitle.ControlStyle.MergeWith(Items.Title.Style)
lblStartContinueText.ControlStyle.MergeWith(Items.StartContinueText.Style)
lblEndContinueText.ControlStyle.MergeWith(Items.EndContinueText.Style)
LayoutAppointmentImages()
statusContainer.Controls.Add(Items.StatusControl)
startTimeClockContainer.Controls.Add(Items.StartTimeClock)
endTimeClockContainer.Controls.Add(Items.EndTimeClock)
End Sub
Private Sub LayoutAppointmentImages()
Dim count As Integer = Items.Images.Count
Dim row As New HtmlTableRow()
row.Cells.Add(New HtmlTableCell())
For i As Integer = 0 To count - 1
Dim cell As New HtmlTableCell()
AddImage(cell, Items.Images(i))
row.Cells.Add(cell)
Next i
imageContainer.Rows.Add(row)
Items.StartContinueArrow.ImageProperties.AssignToControl(imgStartContinueArrow, False)
Items.EndContinueArrow.ImageProperties.AssignToControl(imgEndContinueArrow, False)
End Sub
Private Sub AddImage(ByVal targetCell As HtmlTableCell, ByVal imageItem As AppointmentImageItem)
Dim image As New Image()
imageItem.ImageProperties.AssignToControl(image, False)
targetCell.Controls.Add(image)
End Sub
End Class
@@ -0,0 +1,67 @@
<%--
{************************************************************************************}
{ }
{ DO NOT MODIFY THIS FILE! }
{ }
{ It will be overwritten without prompting when a new version becomes }
{ available. All your changes will be lost. }
{ }
{ This file contains the default template and is required for the appointment }
{ rendering. Improper modifications may result in incorrect appearance of the }
{ appointment. }
{ }
{ In order to create and use your own custom template, perform the following }
{ steps: }
{ 1. Save a copy of this file with a different name in another location. }
{ 2. Add a Register tag in the .aspx page header for each template you use, }
{ as follows: <%@ Register Src="PathToTemplateFile" TagName="NameOfTemplate"}
{ TagPrefix="ShortNameOfTemplate" %> }
{ 3. In the .aspx page find the tags for different scheduler views within }
{ the ASPxScheduler control tag. Insert template tags into the tags }
{ for the views which should be customized. }
{ The template tag should satisfy the following pattern: }
{ <Templates> }
{ <HorizontalSameDayAppointmentTemplate> }
{ <ShortNameOfTemplate: NameOfTemplate runat="server"/> }
{ </HorizontalSameDayAppointmentTemplate> }
{ </Templates> }
{ where ShortNameOfTemplate, NameOfTemplate are the names of the }
{ registered templates, defined in step 2. }
{************************************************************************************}
--%>
<%@ Control Language="vb" AutoEventWireup="true" Inherits="HorizontalSameDayAppointmentTemplate" Codebehind="HorizontalSameDayAppointmentTemplate.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.ASPxScheduler.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxScheduler" TagPrefix="dxwschs" %>
<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web" TagPrefix="dxe" %>
<div id="appointmentDiv" runat="server" class='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.AppointmentStyle.CssClass%>'>
<table width="100%" cellpadding="0" cellspacing="0">
<tr>
<td runat="server" id="statusContainer" valign="top">
</td>
</tr>
<tr>
<td>
<table cellpadding="1" cellspacing="0" width="100%">
<tr valign="middle" align="left">
<td runat="server" id="startTimeClockContainer">
</td>
<td>
<dxe:ASPxLabel runat="server" EnableViewState="false" EncodeHtml="true" ID="lblStartTime" Text='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.StartTimeText.Text%>' Visible='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.StartTimeText.Visible%>'></dxe:ASPxLabel>
</td>
<td runat="server" id="endTimeClockContainer">
</td>
<td>
<dxe:ASPxLabel runat="server" EnableViewState="false" EncodeHtml="true" ID="lblEndTime" Text='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.EndTimeText.Text%>' Visible='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.EndTimeText.Visible%>'></dxe:ASPxLabel>
</td>
<td>
<table id="imageContainer" runat="server" cellpadding="1" cellspacing="0" style="vertical-align: middle;">
</table>
</td>
<td style="width: 100%">
<dxe:ASPxLabel runat="server" EnableViewState="false" EncodeHtml="true" ID="lblTitle" Text='<%#(CType(Container, HorizontalAppointmentTemplateContainer)).Items.Title.Text%>'> </dxe:ASPxLabel>
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
@@ -0,0 +1,87 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class HorizontalSameDayAppointmentTemplate
'''<summary>
'''appointmentDiv control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents appointmentDiv As Global.System.Web.UI.HtmlControls.HtmlGenericControl
'''<summary>
'''statusContainer control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents statusContainer As Global.System.Web.UI.HtmlControls.HtmlTableCell
'''<summary>
'''startTimeClockContainer control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents startTimeClockContainer As Global.System.Web.UI.HtmlControls.HtmlTableCell
'''<summary>
'''lblStartTime control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblStartTime As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''endTimeClockContainer control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents endTimeClockContainer As Global.System.Web.UI.HtmlControls.HtmlTableCell
'''<summary>
'''lblEndTime control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblEndTime As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''imageContainer control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents imageContainer As Global.System.Web.UI.HtmlControls.HtmlTable
'''<summary>
'''lblTitle control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblTitle As Global.DevExpress.Web.ASPxLabel
End Class
@@ -0,0 +1,84 @@
'
'{************************************************************************************}
'{ }
'{ DO NOT MODIFY THIS FILE! }
'{ }
'{ It will be overwritten without prompting when a new version becomes }
'{ available. All your changes will be lost. }
'{ }
'{ This file contains the default template and is required for the appointment }
'{ rendering. Improper modifications may result in incorrect appearance of the }
'{ appointment. }
'{ }
'{ In order to create and use your own custom template, perform the following }
'{ steps: }
'{ 1. Save a copy of this file with a different name in another location. }
'{ 2. Add a Register tag in the .aspx page header for each template you use, }
'{ as follows: <%@ Register Src="PathToTemplateFile" TagName="NameOfTemplate"}
'{ TagPrefix="ShortNameOfTemplate" %> }
'{ 3. In the .aspx page find the tags for different scheduler views within }
'{ the ASPxScheduler control tag. Insert template tags into the tags }
'{ for the views which should be customized. }
'{ The template tag should satisfy the following pattern: }
'{ <Templates> }
'{ <HorizontalSameDayAppointmentTemplate> }
'{ < ShortNameOfTemplate: NameOfTemplate runat="server"/> }
'{ </HorizontalSameDayAppointmentTemplate> }
'{ </Templates> }
'{ where ShortNameOfTemplate, NameOfTemplate are the names of the }
'{ registered templates, defined in step 2. }
'{************************************************************************************}
'
Imports Microsoft.VisualBasic
Imports System
Imports System.Web.UI.WebControls
Imports System.Web.UI.HtmlControls
Imports DevExpress.Web.ASPxScheduler
Imports DevExpress.Web.ASPxScheduler.Drawing
Partial Public Class HorizontalSameDayAppointmentTemplate
Inherits System.Web.UI.UserControl
Private ReadOnly Property Container() As HorizontalAppointmentTemplateContainer
Get
Return CType(Parent, HorizontalAppointmentTemplateContainer)
End Get
End Property
Private ReadOnly Property Items() As HorizontalAppointmentTemplateItems
Get
Return Container.Items
End Get
End Property
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
appointmentDiv.Style.Value = Items.AppointmentStyle.GetStyleAttributes(Page).Value
lblStartTime.ControlStyle.MergeWith(Items.StartTimeText.Style)
lblEndTime.ControlStyle.MergeWith(Items.EndTimeText.Style)
lblTitle.ControlStyle.MergeWith(Items.Title.Style)
LayoutAppointmentImages()
statusContainer.Controls.Add(Container.Items.StatusControl)
startTimeClockContainer.Controls.Add(Container.Items.StartTimeClock)
endTimeClockContainer.Controls.Add(Container.Items.EndTimeClock)
End Sub
Private Sub LayoutAppointmentImages()
Dim count As Integer = Items.Images.Count
Dim row As New HtmlTableRow()
row.Cells.Add(New HtmlTableCell())
For i As Integer = 0 To count - 1
Dim cell As New HtmlTableCell()
AddImage(cell, Items.Images(i))
row.Cells.Add(cell)
Next i
imageContainer.Rows.Add(row)
End Sub
Private Sub AddImage(ByVal targetCell As HtmlTableCell, ByVal imageItem As AppointmentImageItem)
Dim image As New Image()
imageItem.ImageProperties.AssignToControl(image, False)
targetCell.Controls.Add(image)
End Sub
End Class
@@ -0,0 +1,80 @@
<%--
{************************************************************************************}
{ }
{ DO NOT MODIFY THIS FILE! }
{ }
{ It will be overwritten without prompting when a new version becomes }
{ available. All your changes will be lost. }
{ }
{ This file contains the default template and is required for the form }
{ rendering. Improper modifications may result in incorrect behavior of }
{ the appointment form. }
{ }
{ In order to create and use your own custom template, perform the following }
{ steps: }
{ 1. Save a copy of this file with a different name in another location. }
{ 2. Specify the file location as the }
{ 'OptionsForms.AppointmentInplaceEditorFormTemplateUrl' }
{ property of the ASPxScheduler control. }
{ 3. If you need custom fields to be displayed and processed, you should }
{ accomplish steps 4-9; otherwise, go to step 10. }
{ 4. Create a class, derived from the }
{ AppointmentInplaceEditorTemplateContainer, containing custom properties. }
{ This class definition can be located within a class file in the App_Code }
{ folder. }
{ 5. Replace AppointmentInplaceEditorTemplateContainer references in the }
{ template page with the name of the class you've created in step 4. }
{ 6. Handle the AppointmentInplaceEditorFormShowing event to create an }
{ instance of the template container class, defined in step 4, and specify }
{ it as the destination container instead of the default one. }
{ 7. Define a class, which inherits from the }
{ DevExpress.Web.ASPxScheduler.Internal.AppointmentFormController. }
{ This class provides data exchange between the form and the appointment. }
{ You should override ApplyCustomFieldsValues() method of the base class. }
{ 8. Define a class, which inherits from the }
{ DevExpress.Web.ASPxScheduler.Internal.AppointmentFormSaveCallbackCommand. }
{ This class creates an instance of the AppointmentFormController inheritor }
{ (defined in step 7) via the CreateAppointmentFormController method and }
{ overrides the AssignControllerValues method of the base class to collect }
{ user data from the form's editors. }
{ 9. Handle the BeforeExecuteCallbackCommand event. The event handler code }
{ should create an instance of the class defined in step 8, and specify it }
{ as the destination command instead of the default one. }
{ 10. Modify the overall appearance of the page and its layout. }
{ }
{************************************************************************************}--%>
<%@ Control Language="vb" AutoEventWireup="true" Inherits="InplaceEditor" Codebehind="InplaceEditor.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.ASPxScheduler.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxScheduler" TagPrefix="dxwschs" %>
<%@ Register Assembly="DevExpress.Web.ASPxScheduler.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxScheduler.Controls"
TagPrefix="cc1" %>
<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web"
TagPrefix="dxe" %>
<table cellpadding="2"; cellspacing="0" style="width:100%; height:100%">
<tr>
<td style="width:100%" >
<dxe:ASPxMemo ClientInstanceName="_dx" ID="memSubject" runat="server" Width="100%" Rows="5" Text='<%#(CType(Container, AppointmentInplaceEditorTemplateContainer)).Appointment.Subject%>'>
</dxe:ASPxMemo>
</td>
<td valign="top" >
<div>
<cc1:NoBorderButton runat="server" ClientInstanceName="_dx" ID="btnSave" Width="19px" Height="19px" ToolTip="Save"
Image-IsResourcePng="True">
</cc1:NoBorderButton>
</div>
<div style="padding-top:1px;">
<cc1:NoBorderButton runat="server" ClientInstanceName="_dx" ID="btnCancel" Width="19px" Height="19px" ToolTip="Cancel"
CausesValidation="False" Image-IsResourcePng="True">
</cc1:NoBorderButton>
</div>
<div style="padding-top:6px;">
<cc1:NoBorderButton runat="server" ClientInstanceName="_dx" ID="btnEditForm" Width="19px" Height="19px" ToolTip="Open Edit Form..."
CausesValidation="False" Image-IsResourcePng="True">
</cc1:NoBorderButton>
</div>
</td>
</tr>
</table>
@@ -0,0 +1,51 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class InplaceEditor
'''<summary>
'''memSubject control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents memSubject As Global.DevExpress.Web.ASPxMemo
'''<summary>
'''btnSave control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnSave As Global.DevExpress.Web.ASPxScheduler.Controls.NoBorderButton
'''<summary>
'''btnCancel control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnCancel As Global.DevExpress.Web.ASPxScheduler.Controls.NoBorderButton
'''<summary>
'''btnEditForm control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnEditForm As Global.DevExpress.Web.ASPxScheduler.Controls.NoBorderButton
End Class
@@ -0,0 +1,82 @@
'
'{************************************************************************************}
'{ }
'{ DO NOT MODIFY THIS FILE! }
'{ }
'{ It will be overwritten without prompting when a new version becomes }
'{ available. All your changes will be lost. }
'{ }
'{ This file contains the default template and is required for the form }
'{ rendering. Improper modifications may result in incorrect behavior of }
'{ the appointment form. }
'{ }
'{ In order to create and use your own custom template, perform the following }
'{ steps: }
'{ 1. Save a copy of this file with a different name in another location. }
'{ 2. Specify the file location as the }
'{ 'OptionsForms.AppointmentInplaceEditorFormTemplateUrl' }
'{ property of the ASPxScheduler control. }
'{ 3. If you need custom fields to be displayed and processed, you should }
'{ accomplish steps 4-9; otherwise, go to step 10. }
'{ 4. Create a class, derived from the }
'{ AppointmentInplaceEditorTemplateContainer, containing custom properties. }
'{ This class definition can be located within a class file in the App_Code }
'{ folder. }
'{ 5. Replace AppointmentInplaceEditorTemplateContainer references in the }
'{ template page with the name of the class you've created in step 4. }
'{ 6. Handle the AppointmentInplaceEditorFormShowing event to create an }
'{ instance of the template container class, defined in step 4, and specify }
'{ it as the destination container instead of the default one. }
'{ 7. Define a class, which inherits from the }
'{ DevExpress.Web.ASPxScheduler.Internal.AppointmentFormController. }
'{ This class provides data exchange between the form and the appointment. }
'{ You should override ApplyCustomFieldsValues() method of the base class. }
'{ 8. Define a class, which inherits from the }
'{ DevExpress.Web.ASPxScheduler.Internal.AppointmentFormSaveCallbackCommand. }
'{ This class creates an instance of the AppointmentFormController inheritor }
'{ (defined in step 7) via the CreateAppointmentFormController method and }
'{ overrides the AssignControllerValues method of the base class to collect }
'{ user data from the form's editors. }
'{ 9. Handle the BeforeExecuteCallbackCommand event. The event handler code }
'{ should create an instance of the class defined in step 8, and specify it }
'{ as the destination command instead of the default one. }
'{ 10. Modify the overall appearance of the page and its layout. }
'{ }
'{************************************************************************************}
'
Imports Microsoft.VisualBasic
Imports System
Imports DevExpress.Web.ASPxScheduler
Imports DevExpress.Web
Imports DevExpress.Web.Internal
Partial Public Class InplaceEditor
Inherits InplaceEditorBaseFormControl
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
'PrepareChildControls();
memSubject.Focus()
End Sub
Public Overrides Sub DataBind()
MyBase.DataBind()
Dim container As AppointmentInplaceEditorTemplateContainer = CType(Parent, AppointmentInplaceEditorTemplateContainer)
btnCancel.Image.Assign(container.Control.Images.GetInplaceEditorCancelImage(Page))
btnSave.Image.Assign(container.Control.Images.GetInplaceEditorSaveImage(Page))
btnEditForm.Image.Assign(container.Control.Images.GetInplaceEditorEditFormImage(Page))
btnSave.ClientSideEvents.Click = container.SaveHandler
btnCancel.ClientSideEvents.Click = container.CancelHandler
btnEditForm.ClientSideEvents.Click = container.EditFormHandler
End Sub
Protected Overrides Function GetChildEditors() As ASPxEditBase()
Dim edits() As ASPxEditBase = { memSubject }
Return edits
End Function
Protected Overrides Function GetChildButtons() As ASPxButton()
Dim buttons() As ASPxButton = { btnSave, btnCancel, btnEditForm }
Return buttons
End Function
End Class
@@ -0,0 +1,75 @@
<%--
{************************************************************************************}
{ }
{ DO NOT MODIFY THIS FILE! }
{ }
{ It will be overwritten without prompting when a new version becomes }
{ available. All your changes will be lost. }
{ }
{ This file contains the default template and is required for the form }
{ rendering. Improper modifications may result in incorrect behavior of }
{ the appointment form. }
{ }
{ In order to create and use your own custom template, perform the following }
{ steps: }
{ 1. Save a copy of this file with a different name in another location. }
{ 2. Specify the file location as the }
{ 'OptionsForms.RecurrentAppointmentDeleteFormTemplateUrl' }
{ property of the ASPxScheduler control. }
{ 3. If you need to display and process additional controls, you }
{ should accomplish steps 4-6; otherwise, go to step 7. }
{ 4. Create a class, derived from the }
{ RecurrentAppointmentDeleteFormTemplateContainer, }
{ containing additional properties which correspond to your controls. }
{ This class definition can be located within a class file in the App_Code }
{ folder. }
{ 5. Replace RecurrentAppointmentDeleteFormTemplateContainer references in the }
{ template page with the name of the class you've created in step 4. }
{ 6. Handle the RecurrentAppointmentDeleteFormShowing event to create an }
{ instance of the template container class, defined in step 5, and specify }
{ it as the destination container instead of the default one. }
{ 7. Modify the overall appearance of the page and its layout. }
{ }
{************************************************************************************}
--%>
<%@ Control Language="vb" AutoEventWireup="true" Inherits="RecurrentAppointmentDeleteForm" Codebehind="RecurrentAppointmentDeleteForm.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.ASPxScheduler.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxScheduler" TagPrefix="dxwschs" %>
<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web" TagPrefix="dxe" %>
<table style="width:100%; height:100%">
<tr>
<td rowspan="2" style="vertical-align:top;">
<dxe:ASPxImage id="imgWarning" runat="server" EnableViewState="False">
</dxe:ASPxImage>
</td>
<td style="width:100%;">
<dxe:ASPxLabel ID="lblConfirm" runat="server" Text='<%#"Do you want to delete all occurrences of the recurring appointment """ & (CType(Container, DevExpress.Web.ASPxScheduler.RecurrentAppointmentDeleteFormTemplateContainer)).Appointment.Subject & """, or just this one?"%>'/>
</td>
</tr>
<tr>
<td style="width:100%;">
<dxe:ASPxRadioButtonList ID="rbAction" runat="server" ValueType="System.Int32" SelectedIndex="0">
<Border BorderStyle="None" />
<Items>
<dxe:ListEditItem Text="The series" Value="1" />
<dxe:ListEditItem Text="This occurrence" Value="2" />
</Items>
</dxe:ASPxRadioButtonList>
</td>
</tr>
<tr>
<td align="center" style="width:100%" colspan="2">
<table>
<tr>
<td>
<dxe:ASPxButton ID="btnOk" ClientInstanceName="_dx" runat="server" Text="OK" UseSubmitBehavior="false" AutoPostBack="false" EnableViewState="false" Width="91px" />
</td>
<td>
<dxe:ASPxButton ID="btnCancel" ClientInstanceName="_dx" runat="server" Text="Cancel" UseSubmitBehavior="false" AutoPostBack="false" EnableViewState="false"
Width="91px" CausesValidation="False" />
</td>
</tr>
</table>
</td>
</tr>
</table>
@@ -0,0 +1,60 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class RecurrentAppointmentDeleteForm
'''<summary>
'''imgWarning control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents imgWarning As Global.DevExpress.Web.ASPxImage
'''<summary>
'''lblConfirm control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblConfirm As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''rbAction control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents rbAction As Global.DevExpress.Web.ASPxRadioButtonList
'''<summary>
'''btnOk control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnOk As Global.DevExpress.Web.ASPxButton
'''<summary>
'''btnCancel control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnCancel As Global.DevExpress.Web.ASPxButton
End Class
@@ -0,0 +1,71 @@
'
'{************************************************************************************}
'{ }
'{ DO NOT MODIFY THIS FILE! }
'{ }
'{ It will be overwritten without prompting when a new version becomes }
'{ available. All your changes will be lost. }
'{ }
'{ This file contains the default template and is required for the form }
'{ rendering. Improper modifications may result in incorrect behavior of }
'{ the appointment form. }
'{ }
'{ In order to create and use your own custom template, perform the following }
'{ steps: }
'{ 1. Save a copy of this file with a different name in another location. }
'{ 2. Specify the file location as the }
'{ 'OptionsForms.RecurrentAppointmentDeleteFormTemplateUrl' }
'{ property of the ASPxScheduler control. }
'{ 3. If you need to display and process additional controls, you }
'{ should accomplish steps 4-6; otherwise, go to step 7. }
'{ 4. Create a class, derived from the }
'{ RecurrentAppointmentDeleteFormTemplateContainer, }
'{ containing additional properties which correspond to your controls. }
'{ This class definition can be located within a class file in the App_Code }
'{ folder. }
'{ 5. Replace RecurrentAppointmentDeleteFormTemplateContainer references in the }
'{ template page with the name of the class you've created in step 4. }
'{ 6. Handle the RecurrentAppointmentDeleteFormShowing event to create an }
'{ instance of the template container class, defined in step 5, and specify }
'{ it as the destination container instead of the default one. }
'{ 7. Modify the overall appearance of the page and its layout. }
'{ }
'{************************************************************************************}
'
Imports Microsoft.VisualBasic
Imports System
Imports DevExpress.Web.ASPxScheduler
Imports DevExpress.Web
Partial Public Class RecurrentAppointmentDeleteForm
Inherits SchedulerFormControl
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
End Sub
Public Overrides Sub DataBind()
MyBase.DataBind()
Dim container As RecurrentAppointmentDeleteFormTemplateContainer = CType(Parent, RecurrentAppointmentDeleteFormTemplateContainer)
Dim imageProperties As ImageProperties = container.Control.Images.GetWarningImage(Me.Page)
AssignImageProperties(imgWarning, imageProperties)
btnOk.ClientSideEvents.Click = container.ApplyHandler
btnCancel.ClientSideEvents.Click = container.CancelHandler
End Sub
Private Sub AssignImageProperties(ByVal image As ASPxImage, ByVal imageProperties As ImageProperties)
image.ImageUrl = EmptyImageProperties.GetGlobalEmptyImage(Me.Page).Url
image.CssClass = imageProperties.SpriteProperties.CssClass
image.Width = imageProperties.Width
image.Height = imageProperties.Height
image.SpriteLeft = imageProperties.SpriteProperties.Left
image.SpriteTop = imageProperties.SpriteProperties.Top
End Sub
Protected Overrides Function GetChildEditors() As ASPxEditBase()
Dim edits() As ASPxEditBase = { lblConfirm, rbAction }
Return edits
End Function
Protected Overrides Function GetChildButtons() As ASPxButton()
Dim buttons() As ASPxButton = { btnOk, btnCancel }
Return buttons
End Function
End Class
@@ -0,0 +1,75 @@
<%--
{************************************************************************************}
{ }
{ DO NOT MODIFY THIS FILE! }
{ }
{ It will be overwritten without prompting when a new version becomes }
{ available. All your changes will be lost. }
{ }
{ This file contains the default template and is required for the form }
{ rendering. Improper modifications may result in incorrect behavior of }
{ the appointment form. }
{ }
{ In order to create and use your own custom template, perform the following }
{ steps: }
{ 1. Save a copy of this file with a different name in another location. }
{ 2. Specify the file location as the }
{ 'OptionsForms.RecurrentAppointmentEditFormTemplateUrl' }
{ property of the ASPxScheduler control. }
{ 3. If you need to display and process additional controls, you }
{ should accomplish steps 4-6; otherwise, go to step 7. }
{ 4. Create a class, derived from the }
{ RecurrentAppointmentEditFormTemplateContainer, }
{ containing additional properties which correspond to your controls. }
{ This class definition can be located within a class file in the App_Code }
{ folder. }
{ 5. Replace RecurrentAppointmentEditFormTemplateContainer references in the }
{ template page with the name of the class you've created in step 4. }
{ 6. Handle the RecurrentAppointmentEditFormShowing event to create an }
{ instance of the template container class, defined in step 5, and specify }
{ it as the destination container instead of the default one. }
{ 7. Modify the overall appearance of the page and its layout. }
{ }
{************************************************************************************}
--%>
<%@ Control Language="vb" AutoEventWireup="true" Inherits="RecurrentAppointmentEditForm" Codebehind="RecurrentAppointmentEditForm.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.ASPxScheduler.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxScheduler" TagPrefix="dxwschs" %>
<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web" TagPrefix="dxe" %>
<table style="width:100%; height:100%">
<tr>
<td rowspan="2" style="vertical-align:top;">
<dxe:ASPxImage id="Image" runat="server" EnableViewState="False" ImageUrl='<%#Page.ClientScript.GetWebResourceUrl(GetType(ASPxScheduler), "Images.StatusInfo.Info.png")%>' Width="48px" Height="48px" IsPng="true">
</dxe:ASPxImage>
</td>
<td style="width:100%;">
<dxe:ASPxLabel ID="lblConfirm" runat="server" Text='<%#"""" & (CType(Container, DevExpress.Web.ASPxScheduler.RecurrentAppointmentEditFormTemplateContainer)).Appointment.Subject & """ is a recurring appointment. Do you want to open only this occurrence or the series?"%>'/>
</td>
</tr>
<tr>
<td style="width:100%;">
<dxe:ASPxRadioButtonList ID="rbAction" runat="server" ValueType="System.Int32" SelectedIndex="0">
<Border BorderStyle="None" />
<Items>
<dxe:ListEditItem Text="The series" Value="1" />
<dxe:ListEditItem Text="This occurrence" Value="2" />
</Items>
</dxe:ASPxRadioButtonList>
</td>
</tr>
<tr>
<td align="center" style="width:100%" colspan="2">
<table>
<tr>
<td>
<dxe:ASPxButton ID="btnOk" ClientInstanceName="_dx" runat="server" Text="OK" UseSubmitBehavior="false" AutoPostBack="false" EnableViewState="false" Width="91px" />
</td>
<td>
<dxe:ASPxButton ID="btnCancel" ClientInstanceName="_dx" runat="server" Text="Cancel" UseSubmitBehavior="false" AutoPostBack="false" EnableViewState="false"
Width="91px" CausesValidation="False" />
</td>
</tr>
</table>
</td>
</tr>
</table>
@@ -0,0 +1,60 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class RecurrentAppointmentEditForm
'''<summary>
'''Image control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents Image As Global.DevExpress.Web.ASPxImage
'''<summary>
'''lblConfirm control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblConfirm As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''rbAction control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents rbAction As Global.DevExpress.Web.ASPxRadioButtonList
'''<summary>
'''btnOk control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnOk As Global.DevExpress.Web.ASPxButton
'''<summary>
'''btnCancel control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnCancel As Global.DevExpress.Web.ASPxButton
End Class
@@ -0,0 +1,64 @@
'
'{************************************************************************************}
'{ }
'{ DO NOT MODIFY THIS FILE! }
'{ }
'{ It will be overwritten without prompting when a new version becomes }
'{ available. All your changes will be lost. }
'{ }
'{ This file contains the default template and is required for the form }
'{ rendering. Improper modifications may result in incorrect behavior of }
'{ the appointment form. }
'{ }
'{ In order to create and use your own custom template, perform the following }
'{ steps: }
'{ 1. Save a copy of this file with a different name in another location. }
'{ 2. Specify the file location as the }
'{ 'OptionsForms.RecurrentAppointmentEditFormTemplateUrl' }
'{ property of the ASPxScheduler control. }
'{ 3. If you need to display and process additional controls, you }
'{ should accomplish steps 4-6; otherwise, go to step 7. }
'{ 4. Create a class, derived from the }
'{ RecurrentAppointmentEditFormTemplateContainer, }
'{ containing additional properties which correspond to your controls. }
'{ This class definition can be located within a class file in the App_Code }
'{ folder. }
'{ 5. Replace RecurrentAppointmentEditFormTemplateContainer references in the }
'{ template page with the name of the class you've created in step 4. }
'{ 6. Handle the RecurrentAppointmentEditFormShowing event to create an }
'{ instance of the template container class, defined in step 5, and specify }
'{ it as the destination container instead of the default one. }
'{ 7. Modify the overall appearance of the page and its layout. }
'{ }
'{************************************************************************************}
'
Imports Microsoft.VisualBasic
Imports System
Imports DevExpress.Web.ASPxScheduler
Imports DevExpress.Web
Partial Public Class RecurrentAppointmentEditForm
Inherits SchedulerFormControl
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
'PrepareChildControls();
End Sub
Public Overrides Sub DataBind()
MyBase.DataBind()
Dim container As RecurrentAppointmentEditFormTemplateContainer = CType(Parent, RecurrentAppointmentEditFormTemplateContainer)
btnOk.ClientSideEvents.Click = container.ApplyHandler
btnCancel.ClientSideEvents.Click = container.CancelHandler
End Sub
Protected Overrides Function GetChildEditors() As ASPxEditBase()
Dim edits() As ASPxEditBase = { lblConfirm, rbAction }
Return edits
End Function
Protected Overrides Function GetChildButtons() As ASPxButton()
Dim buttons() As ASPxButton = { btnOk, btnCancel }
Return buttons
End Function
End Class
@@ -0,0 +1,23 @@
<%@ Control Language="vb" AutoEventWireup="true" Inherits="ReminderForm" Codebehind="ReminderForm.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web"
TagPrefix="dxe" %>
<table width="100%" cellpadding="0" cellspacing="0" style="padding-bottom:15px;">
<tr><td>
<dxe:ASPxListBox ID="lbItems" runat="server" Width="100%" style="padding-bottom:15px;"></dxe:ASPxListBox>
</td></tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
<tr>
<td style="width:100%;"><dxe:ASPxButton ID="btnDismissAll" runat="server" Text="Dismiss All" AutoPostBack="false"></dxe:ASPxButton></td>
<td style="width:80px;" align="right"><dxe:ASPxButton ID="btnDismiss" runat="server" Text="Dismiss" Width="80px" AutoPostBack="false"></dxe:ASPxButton></td>
</tr>
<tr>
<td colspan="2" style="padding:8px 0 4px 0;"><dxe:ASPxLabel ID="lblClickSnooze" runat="server" Text="Click Snooze to be reminded again in:"></dxe:ASPxLabel></td>
</tr>
<tr>
<td style="width:100%;padding-right:20px;"><dxe:ASPxComboBox ID="cbSnooze" runat="server" Width="100%">
</dxe:ASPxComboBox></td>
<td style="width:80px;"><dxe:ASPxButton ID="btnSnooze" runat="server" Text="Snooze" Width="80px" AutoPostBack="false"></dxe:ASPxButton></td>
</tr>
</table>
@@ -0,0 +1,69 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class ReminderForm
'''<summary>
'''lbItems control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lbItems As Global.DevExpress.Web.ASPxListBox
'''<summary>
'''btnDismissAll control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnDismissAll As Global.DevExpress.Web.ASPxButton
'''<summary>
'''btnDismiss control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnDismiss As Global.DevExpress.Web.ASPxButton
'''<summary>
'''lblClickSnooze control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblClickSnooze As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''cbSnooze control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents cbSnooze As Global.DevExpress.Web.ASPxComboBox
'''<summary>
'''btnSnooze control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnSnooze As Global.DevExpress.Web.ASPxButton
End Class
@@ -0,0 +1,67 @@
Imports Microsoft.VisualBasic
Imports System
Imports System.Data
Imports System.Configuration
Imports System.Collections
Imports System.Web
Imports System.Web.Security
Imports System.Web.UI
Imports System.Web.UI.WebControls
Imports System.Web.UI.WebControls.WebParts
Imports System.Web.UI.HtmlControls
Imports DevExpress.Web.ASPxScheduler
Imports DevExpress.XtraScheduler
Imports DevExpress.Web.ASPxScheduler.Internal
Imports DevExpress.Web
Imports DevExpress.XtraScheduler.Native
Imports DevExpress.XtraScheduler.Localization
Partial Public Class ReminderForm
Inherits SchedulerFormControl
Public Sub New()
MyBase.New()
End Sub
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
'PrepareChildControls();
End Sub
Public Overrides Sub DataBind()
MyBase.DataBind()
Dim container As RemindersFormTemplateContainer = CType(Parent, RemindersFormTemplateContainer)
btnDismiss.ClientSideEvents.Click = container.DismissReminderHandler
btnDismissAll.ClientSideEvents.Click = container.DismissAllRemindersHandler
btnSnooze.ClientSideEvents.Click = container.SnoozeRemindersHandler
InitItemListBox(container)
InitSnoozeCombo(container)
End Sub
Private Sub InitItemListBox(ByVal container As RemindersFormTemplateContainer)
Dim reminders As ReminderCollection = container.Reminders
Dim count As Integer = reminders.Count
For i As Integer = 0 To count - 1
Dim reminder As Reminder = reminders(i)
Dim item As New ListEditItem(reminder.Subject, i)
lbItems.Items.Add(item)
Next i
lbItems.SelectedIndex = 0
End Sub
Private Sub InitSnoozeCombo(ByVal container As RemindersFormTemplateContainer)
cbSnooze.Items.Clear()
Dim timeSpans() As TimeSpan = container.SnoozeTimeSpans
Dim count As Integer = timeSpans.Length
For i As Integer = 0 To count - 1
Dim timeSpan As TimeSpan = timeSpans(i)
cbSnooze.Items.Add(New ListEditItem(container.ConvertSnoozeTimeSpanToString(timeSpan), timeSpan))
Next i
cbSnooze.SelectedIndex = 4
End Sub
Protected Overrides Function GetChildEditors() As ASPxEditBase()
Dim edits() As ASPxEditBase = { lbItems, lblClickSnooze, cbSnooze }
Return edits
End Function
Protected Overrides Function GetChildButtons() As ASPxButton()
Dim buttons() As ASPxButton = { btnDismissAll, btnDismiss, btnSnooze }
Return buttons
End Function
End Class
@@ -0,0 +1,21 @@
<%@ Control Language="vb" AutoEventWireup="true" Inherits="UserForms_SelectionToolTip" Codebehind="SelectionToolTip.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.v15.2" Namespace="DevExpress.Web"
TagPrefix="dxe" %>
<div runat="server" id="buttonDiv">
<dxe:ASPxButton ID="btnShowMenu" runat="server" AutoPostBack="False" AllowFocus="False">
<Border BorderWidth="0px" />
<Paddings Padding="0px" />
<FocusRectPaddings Padding="4px" />
<FocusRectBorder BorderStyle="None" BorderWidth="0px" />
</dxe:ASPxButton>
</div>
<script type="text/javascript" id="dxss_">
ASPxClientSelectionToolTip = _aspxCreateClass(ASPxClientToolTipBase, {
Initialize: function() {
ASPxClientUtils.AttachEventToElement(this.controls.buttonDiv, "click", _aspxCreateDelegate(this.OnButtonDivClick, this));
},
OnButtonDivClick: function(s,e) {
this.ShowViewMenu(s);
}
});
</script>
@@ -0,0 +1,33 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class UserForms_SelectionToolTip
'''<summary>
'''buttonDiv control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents buttonDiv As Global.System.Web.UI.HtmlControls.HtmlGenericControl
'''<summary>
'''btnShowMenu control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents btnShowMenu As Global.DevExpress.Web.ASPxButton
End Class
@@ -0,0 +1,40 @@
Imports Microsoft.VisualBasic
Imports System
Imports System.Data
Imports System.Configuration
Imports System.Collections
Imports System.Web
Imports System.Web.Security
Imports System.Web.UI
Imports System.Web.UI.WebControls
Imports System.Web.UI.WebControls.WebParts
Imports System.Web.UI.HtmlControls
Imports DevExpress.Web.ASPxScheduler
Imports DevExpress.Web.ASPxScheduler.Internal
Imports DevExpress.Web
Partial Public Class UserForms_SelectionToolTip
Inherits ASPxSchedulerToolTipBase
Public Overrides ReadOnly Property ToolTipShowStem() As Boolean
Get
Return False
End Get
End Property
Public Overrides ReadOnly Property ClassName() As String
Get
Return "ASPxClientSelectionToolTip"
End Get
End Property
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
DevExpress.Web.ASPxWebControl.RegisterBaseScript(Page)
End Sub
Protected Overrides Sub OnLoad(ByVal e As EventArgs)
MyBase.OnLoad(e)
btnShowMenu.Image.Assign(GetSmartTagImage())
End Sub
Protected Overrides Function GetChildControls() As Control()
Dim controls() As Control = { buttonDiv }
Return controls
End Function
End Class
@@ -0,0 +1,74 @@
<%--
{************************************************************************************}
{ }
{ DO NOT MODIFY THIS FILE! }
{ }
{ It will be overwritten without prompting when a new version becomes }
{ available. All your changes will be lost. }
{ }
{ This file contains the default template and is required for the appointment }
{ rendering. Improper modifications may result in incorrect appearance of the }
{ appointment. }
{ }
{ In order to create and use your own custom template, perform the following }
{ steps: }
{ 1. Save a copy of this file with a different name in another location. }
{ 2. Add a Register tag in the .aspx page header for each template you use, }
{ as follows: <%@ Register Src="PathToTemplateFile" TagName="NameOfTemplate"}
{ TagPrefix="ShortNameOfTemplate" %> }
{ 3. In the .aspx page find the tags for different scheduler views within }
{ the ASPxScheduler control tag. Insert template tags into the tags }
{ for the views which should be customized. }
{ The template tag should satisfy the following pattern: }
{ <Templates> }
{ <VerticalAppointmentTemplate> }
{ < ShortNameOfTemplate: NameOfTemplate runat="server"/> }
{ </VerticalAppointmentTemplate> }
{ </Templates> }
{ where ShortNameOfTemplate, NameOfTemplate are the names of the }
{ registered templates, defined in step 2. }
{************************************************************************************}
--%>
<%@ Control Language="vb" AutoEventWireup="true" Inherits="VerticalAppointmentTemplate" Codebehind="VerticalAppointmentTemplate.ascx.vb" %>
<%@ Register Assembly="DevExpress.Web.ASPxScheduler.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web.ASPxScheduler" TagPrefix="dxwschs" %>
<%@ Register Assembly="DevExpress.Web.v15.2, Version=15.2.5.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" Namespace="DevExpress.Web" TagPrefix="dxe" %>
<div id="appointmentDiv" runat="server" class='<%#(CType(Container, VerticalAppointmentTemplateContainer)).Items.AppointmentStyle.CssClass%>'>
<table width="100%" cellpadding="0" cellspacing="0">
<tr valign="top" >
<td runat="server" id="statusContainer">
</td>
<td style="width:100%">
<table cellpadding="1" cellspacing="0" width="100%">
<tr valign="top">
<td>
<table id="imageContainer" runat="server" cellpadding="1" cellspacing="0" style="text-align: center">
<tr><td></td></tr>
</table>
</td>
<td style="width:100%">
<table width="100%" cellpadding="1" cellspacing="0" >
<tr>
<td>
<dxe:ASPxLabel runat="server" EnableViewState="false" EncodeHtml="true" ID="lblStartTime" Text='<%#(CType(Container, VerticalAppointmentTemplateContainer)).Items.StartTimeText.Text%>' Visible='<%#(CType(Container, VerticalAppointmentTemplateContainer)).Items.StartTimeText.Visible%>'></dxe:ASPxLabel>
<dxe:ASPxLabel runat="server" EnableViewState="false" EncodeHtml="true" style="margin-left: -4px;" ID="lblEndTime" Text='<%#(CType(Container, VerticalAppointmentTemplateContainer)).Items.EndTimeText.Text%>' Visible='<%#(CType(Container, VerticalAppointmentTemplateContainer)).Items.EndTimeText.Visible%>'></dxe:ASPxLabel>
<dxe:ASPxLabel runat="server" EnableViewState="false" EncodeHtml="true" ID="lblTitle" Text='<%#(CType(Container, VerticalAppointmentTemplateContainer)).Items.Title.Text%>'></dxe:ASPxLabel>
</td>
</tr>
<tr>
<td>
<div runat="server" id="horizontalSeparator" class='<%#(CType(Container, VerticalAppointmentTemplateContainer)).Items.HorizontalSeparator.Style.CssClass%>' visible='<%#(CType(Container, VerticalAppointmentTemplateContainer)).Items.HorizontalSeparator.Visible%>'></div>
</td>
</tr>
<tr>
<td>
<dxe:ASPxLabel runat="server" EnableViewState="false" EncodeHtml="true" ID="lblDescription" Text='<%#(CType(Container, VerticalAppointmentTemplateContainer)).Items.Description.Text%>'></dxe:ASPxLabel>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
@@ -0,0 +1,87 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Partial Public Class VerticalAppointmentTemplate
'''<summary>
'''appointmentDiv control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents appointmentDiv As Global.System.Web.UI.HtmlControls.HtmlGenericControl
'''<summary>
'''statusContainer control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents statusContainer As Global.System.Web.UI.HtmlControls.HtmlTableCell
'''<summary>
'''imageContainer control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents imageContainer As Global.System.Web.UI.HtmlControls.HtmlTable
'''<summary>
'''lblStartTime control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblStartTime As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''lblEndTime control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblEndTime As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''lblTitle control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblTitle As Global.DevExpress.Web.ASPxLabel
'''<summary>
'''horizontalSeparator control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents horizontalSeparator As Global.System.Web.UI.HtmlControls.HtmlGenericControl
'''<summary>
'''lblDescription control.
'''</summary>
'''<remarks>
'''Auto-generated field.
'''To modify move field declaration from designer file to code-behind file.
'''</remarks>
Protected WithEvents lblDescription As Global.DevExpress.Web.ASPxLabel
End Class
@@ -0,0 +1,80 @@
'
'{************************************************************************************}
'{ }
'{ DO NOT MODIFY THIS FILE! }
'{ }
'{ It will be overwritten without prompting when a new version becomes }
'{ available. All your changes will be lost. }
'{ }
'{ This file contains the default template and is required for the appointment }
'{ rendering. Improper modifications may result in incorrect appearance of the }
'{ appointment. }
'{ }
'{ In order to create and use your own custom template, perform the following }
'{ steps: }
'{ 1. Save a copy of this file with a different name in another location. }
'{ 2. Add a Register tag in the .aspx page header for each template you use, }
'{ as follows: <%@ Register Src="PathToTemplateFile" TagName="NameOfTemplate"}
'{ TagPrefix="ShortNameOfTemplate" %> }
'{ 3. In the .aspx page find the tags for different scheduler views within }
'{ the ASPxScheduler control tag. Insert template tags into the tags }
'{ for the views which should be customized. }
'{ The template tag should satisfy the following pattern: }
'{ <Templates> }
'{ <VerticalAppointmentTemplate> }
'{ < ShortNameOfTemplate: NameOfTemplate runat="server"/> }
'{ </VerticalAppointmentTemplate> }
'{ </Templates> }
'{ where ShortNameOfTemplate, NameOfTemplate are the names of the }
'{ registered templates, defined in step 2. }
'{************************************************************************************}
'
Imports Microsoft.VisualBasic
Imports System
Imports System.Web.UI.WebControls
Imports System.Web.UI.HtmlControls
Imports DevExpress.Web.ASPxScheduler
Imports DevExpress.Web.ASPxScheduler.Drawing
Partial Public Class VerticalAppointmentTemplate
Inherits System.Web.UI.UserControl
Private ReadOnly Property Container() As VerticalAppointmentTemplateContainer
Get
Return CType(Parent, VerticalAppointmentTemplateContainer)
End Get
End Property
Private ReadOnly Property Items() As VerticalAppointmentTemplateItems
Get
Return Container.Items
End Get
End Property
Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
appointmentDiv.Style.Value = Items.AppointmentStyle.GetStyleAttributes(Page).Value
horizontalSeparator.Style.Value = Items.HorizontalSeparator.Style.GetStyleAttributes(Page).Value
lblStartTime.ControlStyle.MergeWith(Items.StartTimeText.Style)
lblEndTime.ControlStyle.MergeWith(Items.EndTimeText.Style)
lblTitle.ControlStyle.MergeWith(Items.Title.Style)
lblDescription.ControlStyle.MergeWith(Items.Description.Style)
statusContainer.Controls.Add(Items.StatusControl)
LayoutAppointmentImages()
End Sub
Private Sub LayoutAppointmentImages()
Dim count As Integer = Items.Images.Count
For i As Integer = 0 To count - 1
Dim row As New HtmlTableRow()
Dim cell As New HtmlTableCell()
AddImage(cell, Items.Images(i))
row.Cells.Add(cell)
imageContainer.Rows.Add(row)
Next i
End Sub
Private Sub AddImage(ByVal targetCell As HtmlTableCell, ByVal imageItem As AppointmentImageItem)
Dim image As New Image()
imageItem.ImageProperties.AssignToControl(image, False)
targetCell.Controls.Add(image)
End Sub
End Class