dhtmlxScheduler for ASP.. NET灯箱和服务器端控制器

本文关键字:服务器端 控制器 for ASP NET dhtmlxScheduler | 更新日期: 2023-09-27 17:53:51

我们在dhtmlxScheduler中有自定义灯箱的问题,因为在您的示例中您使用了HTML控制器。我们可以在我们的自定义灯箱中使用服务器端控制器吗?顺便问一下,你是否在用户控制器中放置了自定义表单

<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="uc_taskFrom.ascx.cs" Inherits="Compudata_ProjectManager.userController.uc_taskFrom" %>
<div>
<!-- begin of Content Create TaskForm -->
<!-- Script manager-->
   <asp:ScriptManager ID="ScriptManager1" runat="server">
   </asp:ScriptManager>
   <!-- Validation Summary msg vs_TaskForm-->
   <asp:ValidationSummary ID="vs_TaskForm" runat="server" ForeColor="#CC0000" />
   <asp:UpdatePanel ID="UpdatePanel1" runat="server">
      <ContentTemplate>
      <!-- begin of Content Create TaskForm -->
         <asp:Panel ID="Panel1" runat="server" GroupingText="Create New Task">
            <table>
               <tr>
                  <td>
                     <label>
                        Project:</label>
                  </td>
                  <td>
                     <asp:DropDownList ID="ddl_projectsList" runat="server" DataSourceID="SqlDataSourceProjectList"
                        DataTextField="projectName" DataValueField="projectID" AppendDataBoundItems="True"
                        OnSelectedIndexChanged="ddl_projectsList_SelectedIndexChanged" AutoPostBack="True">
                        <asp:ListItem Value="-1">Select Project</asp:ListItem>
                     </asp:DropDownList>
                     <asp:CompareValidator ID="cv_projectList" runat="server" ControlToValidate="ddl_projectsList"
                        ErrorMessage="Select Project" ForeColor="#FC0000" Operator="NotEqual" ValueToCompare="-1">*</asp:CompareValidator>
                     <asp:SqlDataSource ID="SqlDataSourceProjectList" runat="server" ConnectionString="<%$ ConnectionStrings:Compudata_ProjectManagerConnection %>"
                        SelectCommand="SELECT [projectID], [projectName] FROM [Projects] ORDER BY [projectName]">
                     </asp:SqlDataSource>
                  </td>
               </tr>
               <tr>
                  <td>
                     <label>
                        Task Name:</label><em>*</em>
                  </td>
                  <td>
                     <asp:TextBox ID="txtb_taskName" runat="server"></asp:TextBox>
                     <asp:RequiredFieldValidator ID="rfv_taskName" runat="server" ControlToValidate="txtb_taskName"
                        ErrorMessage="Enter Task Name" ForeColor="#F60000">*</asp:RequiredFieldValidator>
                  </td>
               </tr>
               <tr>
                  <td>
                     Default Tech:
                  </td>
                  <td>
                     <asp:Literal ID="lit_dafaultTech" runat="server"></asp:Literal>
                  </td>
               </tr>
               <tr>
                  <td>
                     <label>
                        Assigned To :</label><em>*</em>
                  </td>
                  <td>
                     <asp:DropDownList ID="ddl_usersList" runat="server" AppendDataBoundItems="True" DataSourceID="SqlDataSourceUserList"
                        DataTextField="UserName" DataValueField="UserId">
                     </asp:DropDownList>
                     <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="ddl_usersList"
                        CssClass="Validator" ErrorMessage="select Tech" InitialValue="-1">*</asp:RequiredFieldValidator>
                     <asp:SqlDataSource ID="SqlDataSourceUserList" runat="server" ConnectionString="<%$ ConnectionStrings:Compudata_ProjectManagerConnection %>"
                        SelectCommand="SELECT [UserId], [UserName] FROM [vw_aspnet_Users]"></asp:SqlDataSource>
                  </td>
               </tr>
               <tr>
                  <td>
                     <label>
                        Status :</label><em>*</em>
                  </td>
                  <td>
                     <asp:DropDownList ID="ddl_status" runat="server" AppendDataBoundItems="True">
                     </asp:DropDownList>
                     <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="ddl_status"
                        ErrorMessage="select Status" InitialValue="-1" CssClass="Validator">*</asp:RequiredFieldValidator>
                     <asp:SqlDataSource ID="status_sqlDS" runat="server" ConnectionString="<%$ ConnectionStrings:Compudata_ProjectManagerConnection %>"
                        SelectCommand="GetAllStatus" SelectCommandType="StoredProcedure"></asp:SqlDataSource>
                  </td>
               </tr>
               <tr>
                  <td>
                     <label>
                        Priorty:</label><em>*</em>
                  </td>
                  <td>
                     <asp:DropDownList ID="ddl_priority" runat="server" AppendDataBoundItems="True">
                     </asp:DropDownList>
                     <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="ddl_priority"
                        ErrorMessage="Select one" CssClass="Validator" InitialValue="-1">*</asp:RequiredFieldValidator>
                     <asp:SqlDataSource ID="priority_sqlDC" runat="server" ConnectionString="<%$ ConnectionStrings:Compudata_ProjectManagerConnection %>"
                        SelectCommand="GetAllPriority" SelectCommandType="StoredProcedure"></asp:SqlDataSource>
                  </td>
               </tr>
               <tr>
                  <td>
                     <label>
                        Estimate Time eg(1.50):</label>
                  </td>
                  <td>
                     <asp:TextBox ID="txtb_estTime" runat="server" Style="direction: ltr"></asp:TextBox>
                  </td>
               </tr>
               <tr>
                  <td>
                     <label>
                        Description:</label><em>*</em>
                  </td>
                  <td>
                     <asp:TextBox ID="txtb_Description" runat="server" TextMode="MultiLine"
                        Width="600px" Height="300px"></asp:TextBox>
                  </td>
               </tr>
               <tr>
                  <td>
                  </td>
               </tr>
               <tr>
                  <td colspan="2">
                                          <label>
                        Send Email:
                     </label>
                     <asp:CheckBox ID="ch_sendEmail" runat="server" Text="Send Email to assigned Tech"
                        Checked="True" />
                  </td>
               </tr>
                                 <tr>
                  <td>
                     <label>Start Date: </label>
                  </td>
                  <td>
                  <asp:TextBox ID="txtb_startDate" runat="server"></asp:TextBox> 
                  </td>
               </tr>
                  <tr>
                  <td>
                     <label>End Date: </label>
                  </td>
                  <td>
                  <asp:TextBox ID="txtb_endDate" runat="server" CssClass=".datetimepicker"></asp:TextBox> 
                  </td>
               </tr>
                      <tr>
                  <td>
                     <label>show on Calendar </label>
                  </td>
                  <td>
                  <asp:CheckBox ID="chb_calendar" runat="server" Text="show on Calendar"></asp:CheckBox> 
                  </td>
               </tr>
               <tr>
                  <td>
                     &nbsp;
                     <asp:Label ID="lblMessage" runat="server"></asp:Label>
                  </td>
                  <td>
                     <asp:Button ID="btn_createTask" runat="server" Text="Create Task" OnClick="createTask_Click" />
                     <asp:Button ID="Button2" runat="server" Text="Cancel" />
                  </td>
               </tr>
            </table>
            <br />
            <!-- begin of Web template option  -->
            <table class="style1">
   <tr>
      <td>
         <asp:LinkButton ID="lnkb_clientRMA" runat="server" 
            onclick="lnkb_clientRMA_Click" 
            >CLIENT RMA RETURN</asp:LinkButton> </td>
      <td>
         <asp:LinkButton ID="lnkb_LG_SERVICE" runat="server" 
            onclick="lnkb_LG_SERVICE_Click">LG SERVICE</asp:LinkButton>  </td>
      <td>
         <asp:LinkButton ID="lnkb_PHONE_REMOTESUPPORT" runat="server" 
            onclick="lnkb_PHONE_REMOTESUPPORT_Click">PHONE/REMOTE SUPPORT</asp:LinkButton> </td>
      <td>
         <asp:LinkButton ID="lnkb_SEAGATE_RMA_RETURN" runat="server" 
            onclick="lnkb_SEAGATE_RMA_RETURN_Click">SEAGATE RMA RETURN</asp:LinkButton>  </td>
      <td>
         <asp:LinkButton ID="lnkb_ON_SITE_SERVICE" runat="server" 
            onclick="lnkb_ON_SITE_SERVICE_Click"> ON-SITE SERVICE</asp:LinkButton></td>
      <td>
         <asp:LinkButton ID="lnkb_ZEISS_RMA_DIAGNOSTIC" runat="server" 
            onclick="lnkb_ZEISS_RMA_DIAGNOSTIC_Click">ZEISS RMA AND DIAGNOSTIC</asp:LinkButton> </td>
   </tr>
   <tr>
      <td>
         <asp:LinkButton ID="lnkb_LENOVO_SERVICE" runat="server" 
            onclick="lnkb_LENOVO_SERVICE_Click">LENOVO SERVICE</asp:LinkButton></td>
      <td>
         <asp:LinkButton ID="lnkb_MONTHLY_SERVICE" runat="server" 
            onclick="lnkb_MONTHLY_SERVICE_Click">MONTHLY SERVICE</asp:LinkButton> </td>
      <td>
         <asp:LinkButton ID="lnkb_Power_Supply_RMA" runat="server" 
            onclick="lnkb_Power_Supply_RMA_Click">Power Supply RMA</asp:LinkButton></td>
      <td>
         <asp:LinkButton ID="lnkb_IN_SHOP_SERVICE" runat="server" 
            onclick="lnkb_IN_SHOP_SERVICE_Click" >IN-SHOP SERVICE</asp:LinkButton></td>
      <td>
         <asp:LinkButton ID="lnkb_VENDOR_RMA_RETURN" runat="server" 
            onclick="lnkb_VENDOR_RMA_RETURN_Click">VENDOR RMA RETURN</asp:LinkButton></td>
      <td>
         &nbsp;</td>
   </tr>
</table>
            <!-- end  of Web template option  -->
         </asp:Panel>
         <!-- end of Content Create TaskForm -->
      </ContentTemplate>
      <Triggers>
         <asp:AsyncPostBackTrigger ControlID="ddl_projectsList" EventName="SelectedIndexChanged" />
      </Triggers>
   </asp:UpdatePanel>
</div>

dhtmlxScheduler for ASP.. NET灯箱和服务器端控制器

你可以把你的web表单放在。aspx页面中,并使用这个函数,这一行将创建iframe窗口

Scheduler.Lightbox.SetExternalLightboxForm("formName.aspx")