Wednesday, March 21, 2012

ASP .net Ajax updatepanel and file upload problem

hi, i am experiencing a problem of file upload and updatepanel. the file upload control does not work in updatepanel ..however i have written a trigger for the page clicking on which full postback will happen. but unfortunately this does not solve the problem. my upload control is not getting the posted file name upon full postback..it is inside the updatepanel. and i have to keep that control inside updatepanel.can anyone help me out this problem..?.thanks in advance...

Create a PostBackTrigger and assign the Button click event in that trigger which uploads the file.


hi,

i think u r using the file upload control only for selecting the file name. do u have any other button to upload that file. if u have a button for uploading put that button outside the update panel. Let the file upload control be inside the update panel

Hope this wil work.


i have used postback trigger but.no action...i have set the client id for adding that template(posting the file to database)...anything else?


it works in one page but fails to work in similar another page.....


In that case i would love to see the code. Would you mind posting that?


it's not working in this page.........

<%@. Page Language="C#" MasterPageFile="~/Master.master" AutoEventWireup="true" CodeFile="AddDocument.aspx.cs"
Inherits="AddDocument" %
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="left" colspan="5" style="height: 28px" valign="middle">
<table border="0" cellpadding="0" cellspacing="0" style="height: 28px">
<tr>
<td id="tdAddProduct" runat="server" align="center" class="bg_tab_select" style="height: 28px;width:129px"
valign="middle" >
<a class="tab_select_text" href="http://links.10026.com/?link=AddDocument.aspx">Add Document</a></td>
<td id="tdblAdd" runat="server" align="center" style="height: 28px; width: 4px;"
valign="middle">
<img height="10" src="http://pics.10026.com/?src=images/blank_w4.gif" width="4" alt="" /></td>
<td id="tdEditProduct" runat="server" align="center" class="bg_tab_unselect" style="height: 28px;width:129px"
valign="middle" >
<a class="tab_unselect_text" href="http://links.10026.com/?link=ViewDocument.aspx">Edit Document</a></td>
<td align="center" style="height: 28px;width:4px" valign="middle" >
<img height="10" src="http://pics.10026.com/?src=images/blank_w4.gif" width="4" alt="" /></td>
<td id="tdViewProduct" runat="server" align="center" class="bg_tab_unselect" style="height: 28px;width:129px"
valign="middle" >
<a class="tab_unselect_text" href="http://links.10026.com/?link=ViewDocument.aspx">View Document</a></td>
<td align="center" style="height: 28px;width:4px" valign="middle" >
<img height="10" src="http://pics.10026.com/?src=images/blank_w4.gif" width="4" alt="" /></td>
</tr>
</table>
</td>
</tr>
<tr>
<td colspan="6" align="center" valign="middle" style="width: 100%;" class="tab_area">
<asp:ScriptManager id="ScriptManager1" runat="server">
</asp:ScriptManager>
<asp:UpdatePanel id="UpdatePanel1" runat="server">
<Triggers>
<asp:PostBackTrigger ControlID="btnAddLeaseDeed" />
</Triggers

<contenttemplate>
<table style="width: 800px" align="left">
<tbody>
<tr>
<td style="width: 100%" valign="middle" align="center" colspan="6">
<asp:Label ID="lblErrorMsg" runat="server" CssClass="nor_txt" ForeColor="Red"></asp:Label></td>
</tr>
<tr>
<td style="width: 100%; height: 90px" valign="middle" align="left" colspan="6">

<table>
<tbody>
<tr>
<td style="width: 158px">
<asp:Label ID="lblSelectedItem" runat="server" CssClass="nor_txt1" Text="Select Document Type:"></asp:Label></td>
<td style="width: 117px">
<asp:DropDownList ID="ddlDocument" runat="server" CssClass="text_box" Width="82px"
OnSelectedIndexChanged="ddlDocument_SelectedIndexChanged" AutoPostBack="True">
<asp:ListItem Selected="True" Text="--Select--" Value="0"></asp:ListItem>
</asp:DropDownList></td>
</tr>
<tr>
<td style="width: 158px">
<asp:Label ID="lblInsuranceType" runat="server" CssClass="nor_txt1" Text="Select Insurance Type:"
Visible="False"></asp:Label></td>
<td style="width: 117px">
<asp:DropDownList ID="ddlInsurance" runat="server" CssClass="text_box" Width="81px"
OnSelectedIndexChanged="ddlInsurance_SelectedIndexChanged" AutoPostBack="True"
Visible="False">
</asp:DropDownList></td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td style="width: 100%" valign="middle" align="left" colspan="6">
</td>
</tr>
<tr>
<td style="width: 100%" valign="middle" align="center" colspan="6">
<asp:Panel ID="pnlLeaseDeed" runat="server" Width="100%" Visible="false">
<table style="width: 100%" align="left">
<tbody>
<tr style="font-size: 12pt; font-family: Times New Roman">
<td style="width: 100%" class="side_heading" valign="middle" align="center" colspan="6">
<asp:Label ID="lblLeaseDeed" runat="server" Text="Lease Deed"></asp:Label></td>
</tr>
<tr style="font-size: 12pt; font-family: Times New Roman">
<td style="width: 100%" valign="middle" align="center" colspan="6">
<table style="width: 100%">
<tbody>
<tr>
<td style="width: 150px" align="left">
<asp:Label ID="lblLocation" runat="server" CssClass="nor_txt1" Text="Location:"></asp:Label></td>
<td style="width: 573px" align="left">
<asp:DropDownList ID="ddlLocationLeaseDeed" runat="server" CssClass="text_box">
</asp:DropDownList></td>
</tr>
<tr>
<td style="width: 150px; text-align: left">
<asp:Label ID="lblAddress" runat="server" CssClass="nor_txt1" Text="Address:"></asp:Label></td>
<td style="width: 573px" align="left">
<asp:TextBox ID="txtAddress" runat="server" CssClass="text_box" TextMode="MultiLine"
Rows="3"></asp:TextBox>
<asp:RequiredFieldValidator ID="AddressRequiredFieldValidator" runat="server" CssClass="nor_txt"
ValidationGroup="LeaseDeed" SetFocusOnError="True" ErrorMessage="Address is required"
ControlToValidate="txtAddress">Address is required</asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 150px; height: 56px; text-align: left">
<asp:Label ID="lblDetailsOfLandlord" runat="server" CssClass="nor_txt1" Text="Details Of Landlord :"></asp:Label></td>
<td style="width: 573px" align="left">
<asp:TextBox ID="txtDetailsOfLandlord" runat="server" CssClass="text_box" TextMode="MultiLine"
Rows="3"></asp:TextBox>
<asp:RequiredFieldValidator ID="LandlordRequiredFieldValidator" runat="server" CssClass="nor_txt"
ValidationGroup="LeaseDeed" ErrorMessage="LandLord Details is required" ControlToValidate="txtDetailsOfLandlord"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 150px; height: 22px; text-align: left">
<asp:Label ID="lblTypeOfAgreement" runat="server" CssClass="nor_txt1" Text="Type Of Agreement:"></asp:Label></td>
<td style="width: 573px; height: 22px" align="left">
<asp:TextBox ID="txtTypeOfAgreement" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="AgreeMentRequiredFieldValidator4" runat="server"
CssClass="nor_txt" ValidationGroup="LeaseDeed" ErrorMessage="Type of Agreement is required"
ControlToValidate="txtTypeOfAgreement"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 150px; height: 22px; text-align: left">
<asp:Label ID="Label2" runat="server" CssClass="nor_txt1" Text="Tenure of Agreement:"></asp:Label></td>
<td style="width: 573px; height: 22px" align="left">
<table>
<tbody>
<tr>
<td style="width: 100px">
<asp:Label ID="lblFromDate" runat="server" CssClass="nor_txt1" Text="From Date:"></asp:Label></td>
<td style="width: 296px">
<input id="txtFromDate" class="text_box" readonly type="text" runat="server" />
<asp:Image ID="Img1" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop"
Height="18"></asp:Image>
<asp:RequiredFieldValidator ID="FromDateRequiredFieldValidator" runat="server" CssClass="nor_txt"
ValidationGroup="LeaseDeed" ErrorMessage="From Date is required" ControlToValidate="txtFromDate"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 100px">
<asp:Label ID="lblToDate" runat="server" CssClass="nor_txt1" Text="To Date:"></asp:Label></td>
<td style="width: 296px">
<input id="txtToDate" class="text_box" readonly type="text" runat="server" />
<asp:Image ID="Img2" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop"
Height="18"></asp:Image>
<asp:RequiredFieldValidator ID="ToDateRequiredFieldValidator5" runat="server" CssClass="nor_txt"
ValidationGroup="LeaseDeed" ErrorMessage="To Date is required" ControlToValidate="txtToDate"></asp:RequiredFieldValidator></td>
</tr>
</tbody>
</table>
<asp:CompareValidator ID="CompareValidator1" runat="server" CssClass="nor_txt" ValidationGroup="LeaseDeed"
ErrorMessage="Tenure Of Agreement From Date should be before To Date" ControlToValidate="txtToDate"
Type="Date" Operator="GreaterThan" ControlToCompare="txtFromDate"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 150px; height: 22px" align="left">
<asp:Label ID="lnlMonths" runat="server" CssClass="nor_txt1" Text="Months:"></asp:Label></td>
<td style="width: 573px; height: 22px" align="left">
<asp:TextBox ID="txtMonths" runat="server" CssClass="text_box" ReadOnly="True"></asp:TextBox> <asp:Button
ID="BtnCalcMonth" OnClick="BtnCalcMonth_Click" runat="server" CssClass="text_box"
Text="calculate" BorderStyle="Inset"></asp:Button>
<asp:Label ID="lblErrorMonth" runat="server" CssClass="nor_txt" ForeColor="Red"></asp:Label></td>
</tr>
<tr>
<td style="width: 150px; height: 22px" align="left">
<asp:Label ID="lblArea" runat="server" CssClass="nor_txt1" Text="Super Area(Sq.Ft):"></asp:Label></td>
<td style="width: 573px; height: 22px" align="left">
<asp:TextBox ID="txtArea" runat="server" CssClass="text_box" AutoPostBack="True"
OnTextChanged="txtCurrentRate_TextChanged"></asp:TextBox>
<asp:RequiredFieldValidator ID="AreaRequiredFieldValidator" runat="server" CssClass="nor_txt"
ValidationGroup="LeaseDeed" ErrorMessage="Area is required" ControlToValidate="txtArea"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator2" runat="server" CssClass="nor_txt" ValidationGroup="LeaseDeed"
SetFocusOnError="True" ErrorMessage="Area Should be Numeric" ControlToValidate="txtArea"
Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 150px; height: 22px" align="left">
<asp:Label ID="lblCurrentRent" runat="server" CssClass="nor_txt1" Text="Current Rent(Rs):"></asp:Label></td>
<td style="width: 573px; height: 22px" align="left">
<asp:TextBox ID="txtCurrentRate" runat="server" CssClass="text_box" AutoPostBack="True"
OnTextChanged="txtCurrentRate_TextChanged"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" CssClass="nor_txt"
ValidationGroup="LeaseDeed" ErrorMessage="Current Rent is required" ControlToValidate="txtCurrentRate"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator3" runat="server" CssClass="nor_txt" ValidationGroup="LeaseDeed"
SetFocusOnError="True" ErrorMessage="Current Rent Should be Numeric" ControlToValidate="txtCurrentRate"
Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 150px" align="left">
<asp:Label ID="lblRate" runat="server" CssClass="nor_txt1" Text="Rate:"></asp:Label></td>
<td style="width: 573px" align="left">
<asp:TextBox ID="txtRate" runat="server" CssClass="text_box" ReadOnly="True"></asp:TextBox>
</td>
</tr>
<tr>
<td style="width: 150px; height: 8px" align="left">
<asp:Label ID="lblEscalation" runat="server" CssClass="nor_txt1" Text="Escalations:"></asp:Label></td>
<td style="width: 573px; height: 8px" align="left">
</td>
</tr>
<tr>
<td style="height: 29px" align="center" colspan="2">
<asp:Button ID="btnAddEscalation" OnClick="btnAddEscalation_Click" runat="server"
CssClass="form_button_large" Text="Add Escalation"></asp:Button></td>
</tr>
<tr>
<td align="center" colspan="2">
<asp:Panel ID="pnlEscalation" runat="server" Width="100%">
<asp:DataGrid ID="gvwEscalation" runat="server" CssClass="tebale_border" ForeColor="Black"
Width="710px" Visible="False" OnItemCommand="gvwEscalation_ItemCommand" GridLines="None"
CellPadding="2" BorderWidth="1px" AutoGenerateColumns="False">
<FooterStyle BackColor="Tan" />
<SelectedItemStyle BackColor="DarkSlateBlue" ForeColor="GhostWhite" />
<PagerStyle BackColor="PaleGoldenrod" ForeColor="DarkSlateBlue" HorizontalAlign="Center" />
<AlternatingItemStyle CssClass="alt_grid" />
<ItemStyle CssClass="nor_grid" />
<HeaderStyle CssClass="side_heading" HorizontalAlign="Center" />
<Columns>
<asp:BoundColumn DataField="SlNo" HeaderText="SlNo"></asp:BoundColumn>
<asp:TemplateColumn HeaderText="Amount">
<ItemTemplate>
<asp:TextBox ID="txtAmount" runat="server" CssClass="text_box" Text='<%# DataBinder.Eval(Container.DataItem,"Amount") %>'
Width="120px"></asp:TextBox><asp:RequiredFieldValidator ID="RequiredFieldValidator1"
runat="server" ControlToValidate="txtAmount" ErrorMessage="Amount is mandatory"
ValidationGroup="LeaseDeed">*</asp:RequiredFieldValidator>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="From Date">
<ItemTemplate>
<input id="txtFromDateGrid" runat="server" class="text_box" readonly="readonly" size="20"
type="text" value='<%# DataBinder.Eval(Container.DataItem,"From Date") %>' />
<asp:Image ID="ImgFromDateGrid" runat="server" Height="18" ImageAlign="TextTop" ImageUrl="date_picker.jpg"
Width="20" /><asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server"
ControlToValidate="txtFromDateGrid" ErrorMessage="From Date is mandatory" ValidationGroup="LeaseDeed">*</asp:RequiredFieldValidator>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="To Date">
<ItemTemplate>
<input id="txtToDateGrid" runat="server" class="text_box" readonly="readonly" type="text"
value='<%# DataBinder.Eval(Container.DataItem,"To Date") %>' />
<asp:Image ID="ImgToDate" runat="server" Height="18" ImageAlign="TextTop" ImageUrl="date_picker.jpg"
Width="20" /><asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server"
ControlToValidate="txtToDateGrid" ErrorMessage="To Date is mandatory" ValidationGroup="LeaseDeed">*</asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidatorDate" runat="server" ControlToCompare="txtFromDateGrid"
ControlToValidate="txtToDateGrid" CssClass="nor_txt" ErrorMessage="StartDate>EndDate"
Operator="GreaterThan" ValidationGroup="LeaseDeed"></asp:CompareValidator>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn>
<ItemStyle HorizontalAlign="Center" />
<ItemTemplate>
<asp:Button ID="btnDelete" runat="server" CausesValidation="false" CommandName="Remove"
CssClass="form_button" Text="Remove" />
</ItemTemplate>
<HeaderStyle Width="100px" />
</asp:TemplateColumn>
</Columns>
</asp:DataGrid> </asp:Panel>
</td>
</tr>
<tr>
<td style="width: 150px; height: 22px; text-align: left" align="left">
<asp:Label ID="lblAdvanceRentals" runat="server" CssClass="nor_txt1" Text="Advance Rentals(Rs):"></asp:Label></td>
<td style="width: 573px; height: 22px" align="left">
<asp:TextBox ID="txtAdvanceRentals" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" CssClass="nor_txt"
ValidationGroup="LeaseDeed" ErrorMessage="Advance is required" ControlToValidate="txtAdvanceRentals"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator4" runat="server" CssClass="nor_txt" ValidationGroup="LeaseDeed"
SetFocusOnError="True" ErrorMessage="Advance Rentals Should be Numeric" ControlToValidate="txtAdvanceRentals"
Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 150px; height: 22px; text-align: left">
<asp:Label ID="lblDeposit" runat="server" CssClass="nor_txt1" Text="Deposit:"></asp:Label></td>
<td style="width: 573px; height: 22px" align="left">
<asp:TextBox ID="txtDeposit" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator6" runat="server" CssClass="nor_txt"
ValidationGroup="LeaseDeed" ErrorMessage="Deposit is required" ControlToValidate="txtDeposit"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator5" runat="server" CssClass="nor_txt" ValidationGroup="LeaseDeed"
ErrorMessage="Deposit Should be Numeric" ControlToValidate="txtDeposit" Type="Double"
Operator="DataTypeCheck"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 150px; height: 22px" align="left">
<asp:Label ID="lblLockInPeriod" runat="server" CssClass="nor_txt1" Text="Lock-in Period:"></asp:Label> </td>
<td style="width: 573px; height: 22px" align="left">
<table>
<tbody>
<tr>
<td style="width: 100px; height: 22px">
<asp:Label ID="lblMonth" runat="server" CssClass="nor_txt1" Text="Month:"></asp:Label></td>
<td style="width: 410px; height: 22px">
<asp:DropDownList ID="ddlMonth" runat="server" CssClass="text_box">
</asp:DropDownList>
</td>
</tr>
<tr>
<td style="width: 100px">
<asp:Label ID="lblDate" runat="server" CssClass="nor_txt1" Text="Date:"></asp:Label></td>
<td style="width: 410px">
<input id="txtLocInDate" class="text_box" readonly type="text" runat="server" />
<asp:Image ID="Img4" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop"
Height="18"></asp:Image>
<asp:RequiredFieldValidator ID="RequiredFieldValidator8" runat="server" CssClass="nor_txt"
ValidationGroup="LeaseDeed" ErrorMessage="Date is required" ControlToValidate="txtLocInDate"></asp:RequiredFieldValidator></td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td style="width: 150px; height: 22px" align="left">
<asp:Label ID="lblNoticePeriod" runat="server" CssClass="nor_txt1" Text="Notice Period:"></asp:Label></td>
<td style="width: 573px; height: 22px" align="left">
<asp:TextBox ID="txtNoticePeriod" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator9" runat="server" CssClass="nor_txt"
ValidationGroup="LeaseDeed" ErrorMessage="Notice period is required" ControlToValidate="txtNoticePeriod"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator7" runat="server" CssClass="nor_txt" ValidationGroup="LeaseDeed"
ErrorMessage="Notice Period Should be integer" ControlToValidate="txtNoticePeriod"
Type="Integer" Operator="DataTypeCheck" ValueToCompare="10"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 150px; height: 22px" align="left">
<asp:Label ID="lblAttachment1" runat="server" CssClass="nor_txt1" Text="Attachment :"></asp:Label></td>
<td style="width: 573px; height: 22px" align="left">
<asp:FileUpload ID="fuLeaseDeed" runat="server" CssClass="text_box"></asp:FileUpload>
<asp:RequiredFieldValidator ID="RequiredFieldValidator33" runat="server" CssClass="nor_txt"
ValidationGroup="LeaseDeed" ErrorMessage="Attachment is required" ControlToValidate="fuLeaseDeed"></asp:RequiredFieldValidator>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr style="font-size: 12pt; font-family: Times New Roman">
<td style="width: 728px" valign="middle" align="center" colspan="6">
<asp:Button ID="btnAddLeaseDeed" OnClick="btnAddLeaseDeed_Click" runat="server" CssClass="form_button_large"
Text="Add Lease Deed" ValidationGroup="LeaseDeed"></asp:Button></td>
</tr>
</tbody>
</table>
</asp:Panel>
</td>
</tr>
<tr>
<td style="width: 100%" valign="middle" align="left" colspan="6">
<asp:Panel ID="pnlMotorInsurance" runat="server" Width="100%" Visible="false">

<table style="width: 100%" align="left">
<tbody>
<tr>
<td style="width: 100%" valign="middle" align="center" colspan="6">
<table style="width: 100%">
<tbody>
<tr>
<td class="side_heading" align="center" colspan="2">
<asp:Label ID="lblMotorInsurance" runat="server" Text="Motor Insurance"></asp:Label></td>
</tr>
<tr>
<td style="width: 147px" align="left" colspan="1">
<asp:Label ID="Label3" runat="server" CssClass="nor_txt1" Text="Location:"></asp:Label></td>
<td align="left">
<asp:DropDownList ID="ddlLocationMotorInsurance" runat="server" CssClass="text_box">
</asp:DropDownList></td>
</tr>
<tr>
<td style="width: 147px" align="left" colspan="1">
<asp:Label ID="lblVehicleNo" runat="server" CssClass="nor_txt1" Text="Vehicle No:"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtVehicleNo" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator14" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Vehicle No. is required"
ControlToValidate="txtVehicleNo"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 147px" align="left" colspan="1">
<asp:Label ID="lblModel" runat="server" CssClass="nor_txt1" Text="Model:"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtModel" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator15" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Model is required"
ControlToValidate="txtModel"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 147px" align="left" colspan="1">
<asp:Label ID="lblCapacity" runat="server" CssClass="nor_txt1" Text="Capacity:"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtCapacity" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator16" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Capacity is required"
ControlToValidate="txtCapacity"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 147px" align="left" colspan="1">
<asp:Label ID="lblDateOfPurchase" runat="server" CssClass="nor_txt1" Text="Date Of Purchase:"></asp:Label></td>
<td style="width: 429px" align="left">
<input id="txtDateOfPurchase" class="text_box" readonly type="text" runat="server" /> <asp:Image
ID="Img5" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop"
Height="18"></asp:Image>
<asp:RequiredFieldValidator ID="RequiredFieldValidator10" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" ErrorMessage="Date of Purchase is required"
ControlToValidate="txtDateOfPurchase"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 147px; height: 22px" align="left" colspan="1">
<asp:Label ID="lblPurchaseValue" runat="server" CssClass="nor_txt1" Text="Purchase Value:"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtPurchaseValue" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator17" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Purchase Value is required"
ControlToValidate="txtPurchaseValue"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator8" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance"
SetFocusOnError="True" ErrorMessage="Purchase Value Should be Numeric" ControlToValidate="txtPurchaseValue"
Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 147px; height: 22px" align="left" colspan="1">
<asp:Label ID="lblUserName" runat="server" CssClass="nor_txt1" Text="User Name:"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtUserName" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator18" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="User Name is required"
ControlToValidate="txtUserName"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 147px" align="left" colspan="1">
<asp:Label ID="lblPolicyNo" runat="server" CssClass="nor_txt1" Text="Policy No:"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtPolicyNo" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator19" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Policy No. is required"
ControlToValidate="txtPolicyNo"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 147px; height: 32px" align="left" colspan="1">
<asp:Label ID="lblNameOfInsuranceCompany" runat="server" CssClass="nor_txt1" Text="Name Of Insurance Company:"
Width="162px"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtNameOfInsuranceCompany" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator20" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Name Of Insurance Company is required"
ControlToValidate="txtNameOfInsuranceCompany"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 147px" align="left" colspan="1">
<asp:Label ID="lblRenewalDated" runat="server" CssClass="nor_txt1" Text="Renewal Dated:"></asp:Label></td>
<td style="width: 429px" align="left">
<input id="txtRenewalDated" class="text_box" readonly type="text" runat="server" /> <asp:Image
ID="Img6" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop"
Height="18"></asp:Image>
<asp:RequiredFieldValidator ID="RequiredFieldValidator11" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" ErrorMessage="Renewal Date is required" ControlToValidate="txtRenewalDated"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 147px" align="left" colspan="1">
<asp:Label ID="lblExpiry" runat="server" CssClass="nor_txt1" Text="Expiry:"></asp:Label></td>
<td style="width: 429px" align="left">
<input id="txtExpiry" class="text_box" readonly type="text" runat="server" /> <asp:Image
ID="Img7" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop"
Height="18"></asp:Image>
<asp:RequiredFieldValidator ID="RequiredFieldValidator12" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" ErrorMessage="Expiry Date is required" ControlToValidate="txtExpiry"></asp:RequiredFieldValidator>
<br />
<asp:CompareValidator ID="CompareValidator11" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance"
ErrorMessage="Expiry Date should be after Renewal Date" ControlToValidate="txtExpiry"
Type="Date" Operator="GreaterThan" ControlToCompare="txtRenewalDated"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 147px" align="left" colspan="1">
<asp:Label ID="lblPremiumAmount" runat="server" CssClass="nor_txt1" Text="Premium Amount:"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtPremiumAmount" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator21" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Premium Amount is required"
ControlToValidate="txtPremiumAmount"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator9" runat="server" CssClass="nor_txt" Width="174px"
ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Premium Amount Should be Numeric"
ControlToValidate="txtPremiumAmount" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 147px" align="left" colspan="1">
<asp:Label ID="lblInsuredAmount" runat="server" CssClass="nor_txt1" Text="Insured Amount:"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtInsuredAmount" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator22" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Insured Amount is required"
ControlToValidate="txtInsuredAmount"></asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidator10" runat="server" CssClass="nor_txt" Width="176px"
ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Insured Amount Should be Numeric"
ControlToValidate="txtInsuredAmount" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 147px" align="left" colspan="1">
<asp:Label ID="lblAttachment2" runat="server" CssClass="nor_txt1" Text="Attachment :"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:FileUpload ID="fuMotor" runat="server" CssClass="text_box"></asp:FileUpload>
<asp:RequiredFieldValidator ID="RequiredFieldValidator7" runat="server" CssClass="nor_txt"
ValidationGroup="MotorInsurance" ErrorMessage="Attachment is required" ControlToValidate="fuMotor"></asp:RequiredFieldValidator></td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td style="width: 100%" valign="middle" align="center" colspan="6">
<asp:Button ID="btnAddMotorInsurance" OnClick="btnAddMotorInsurance_Click" runat="server"
CssClass="form_button_large" Text="Add Motor Insurance" ValidationGroup="MotorInsurance">
</asp:Button></td>
</tr>
</tbody>
</table>
</asp:Panel>
</td>
</tr>
<tr>
<td style="width: 100%" valign="middle" align="left" colspan="6">
<asp:Panel ID="pnlOfficeInsurance" runat="server" Width="100%" Visible="false">
<table style="width: 100%" align="left">
<tbody>
<tr>
<td style="width: 100%" class="side_heading" valign="middle" align="center" colspan="6">
<asp:Label ID="lblOfficeInsurance" runat="server" Text="Office Insurance"></asp:Label></td>
</tr>
<tr>
<td style="width: 100%" valign="middle" align="center" colspan="6">
<table style="width: 100%">
<tbody>
<tr>
<td style="width: 150px" align="left">
<asp:Label ID="Label5" runat="server" CssClass="nor_txt1" Text="Location:"></asp:Label></td>
<td style="width: 459px" align="left">
<asp:DropDownList ID="ddlLocationAddOfficeInsurance" runat="server" CssClass="text_box">
</asp:DropDownList></td>
</tr>
<tr>
<td style="width: 150px" align="left">
<asp:Label ID="Label6" runat="server" CssClass="nor_txt1" Text="Policy No:"></asp:Label></td>
<td style="width: 429px; height: 21px" align="left">
<asp:TextBox ID="txtPolicyNoInsurance" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator23" runat="server" CssClass="nor_txt"
ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Policy No. is required"
ControlToValidate="txtPolicyNoInsurance"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 150px" align="left">
<asp:Label ID="lblDateOfIssue" runat="server" CssClass="nor_txt1" Text="Date Of Issue:"></asp:Label></td>
<td style="width: 429px" align="left">
<input id="txtDateOfIssue" class="text_box" readonly type="text" runat="server" />
<asp:Image ID="Img8" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop"
Height="18"></asp:Image>
<asp:RequiredFieldValidator ID="RequiredFieldValidator13" runat="server" CssClass="nor_txt"
ValidationGroup="OfficeInsurance" ErrorMessage="Date of Issue is required" ControlToValidate="txtDateOfIssue"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 150px" align="left">
<asp:Label ID="Label7" runat="server" CssClass="nor_txt1" Text="Name Of Insurance Company:"
Width="166px"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtOfficeInsuranceCompany" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator24" runat="server" CssClass="nor_txt"
ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Name Of Insurance Company is required"
ControlToValidate="txtOfficeInsuranceCompany"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 150px" align="left">
<asp:Label ID="lblNatureOfPolicy" runat="server" CssClass="nor_txt1" Text="Nature Of Policy:"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtNatureOfPolicy" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator25" runat="server" CssClass="nor_txt"
ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Nature Of Policy is required"
ControlToValidate="txtNatureOfPolicy"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 150px; height: 66px; text-align: left" align="left">
<asp:Label ID="lblExpiryDate" runat="server" CssClass="nor_txt1" Text="Expiry Date:"></asp:Label>
</td>
<td style="width: 429px; height: 66px" align="left">
<input id="txtExpairyDate" class="text_box" readonly type="text" runat="server" />
<asp:Image ID="Img9" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop"
Height="18"></asp:Image>
<asp:RequiredFieldValidator ID="RequiredFieldValidator26" runat="server" CssClass="nor_txt"
ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Expairy Date is required"
ControlToValidate="txtExpairyDate"></asp:RequiredFieldValidator><br />
<asp:CompareValidator ID="CompareValidator14" runat="server" CssClass="nor_txt" ValidationGroup="OfficeInsurance"
SetFocusOnError="True" ErrorMessage="Date of issue should be before Expairy Date"
ControlToValidate="txtExpairyDate" Type="Date" Operator="GreaterThan" ControlToCompare="txtDateOfIssue"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 150px" align="left">
<asp:Label ID="Label8" runat="server" CssClass="nor_txt1" Text="Insured Amount:"></asp:Label>
</td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtOfficeInsuranceAmount" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator27" runat="server" CssClass="nor_txt"
ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Premium Amount is required"
ControlToValidate="txtOfficeInsuranceAmount"></asp:RequiredFieldValidator><br />
<asp:CompareValidator ID="CompareValidator12" runat="server" CssClass="nor_txt" Width="174px"
ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Premium Amount Should be Numeric"
ControlToValidate="txtPremiumAmountOffice" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 150px" align="left">
<asp:Label ID="Label9" runat="server" CssClass="nor_txt1" Text="Premium Amount:"></asp:Label>
</td>
<td style="width: 429px" align="left">
<asp:TextBox ID="txtPremiumAmountOffice" runat="server" CssClass="text_box"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator28" runat="server" CssClass="nor_txt"
ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Insured Amount is required"
ControlToValidate="txtPremiumAmountOffice"></asp:RequiredFieldValidator>
<br />
<asp:CompareValidator ID="CompareValidator13" runat="server" CssClass="nor_txt" Width="176px"
ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Insured Amount Should be Numeric"
ControlToValidate="txtPremiumAmountOffice" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></td>
</tr>
<tr>
<td style="width: 150px" align="left">
<asp:Label ID="Label1" runat="server" CssClass="nor_txt1" Text="Attachment :"></asp:Label></td>
<td style="width: 429px" align="left">
<asp:FileUpload ID="fuOffice" runat="server" CssClass="text_box"></asp:FileUpload>
<asp:RequiredFieldValidator ID="RequiredFieldValidator35" runat="server" CssClass="nor_txt"
ValidationGroup="OfficeInsurance" ErrorMessage="Attachment is required" ControlToValidate="fuOffice"></asp:RequiredFieldValidator></td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td style="width: 100%" valign="middle" align="center" colspan="6">
<asp:Button ID="btnAddOfficeInsuranceTemplate" OnClick="btnAddOfficeInsuranceTemplate_Click"
runat="server" CssClass="form_button_large" Text="Add Office Insurance" ValidationGroup="OfficeInsurance">
</asp:Button></td>
</tr>
</tbody>
</table>
</asp:Panel>
</td>
</tr>
<tr>
<td style="width: 100%" valign="middle" align="left" colspan="6">
<asp:Panel ID="pnlAMC" runat="server" Width="100%" Visible="false" HorizontalAlign="Center">
<table style="width: 100%" align="left">
<tbody>
<tr>
<td style="width: 100%; height: 17px; text-align: center" class="side_heading" valign="middle"
align="center" colspan="6">
<asp:Label ID="lblAMC" runat="server" Text="AMC"></asp:Label></td>
</tr>
<tr>
<td style="width: 100%; text-align: center" valign="middle" align="center" colspan="6">
<table style="width: 100%">
<tbody>
<tr>
<td style="width: 147px" align="left">
<asp:Label ID="lblVendorName" runat="server" CssClass="nor_txt1" Text="VendorName:"></asp:Label></td>
<td style="width: 460px" align="left">
<asp:DropDownList ID="ddlVendorName" runat="server" CssClass="text_box" OnSelectedIndexChanged="ddlVendorName_SelectedindexChanged"
AutoPostBack="True">
<asp:ListItem>Vendor Name2</asp:ListItem>
<asp:ListItem>Vendor Name1</asp:ListItem>
</asp:DropDownList></td>
</tr>
<tr>
<td style="width: 147px" align="left">
<asp:Label ID="Label11" runat="server" CssClass="nor_txt1" Text="Address:"></asp:Label></td>
<td style="width: 460px" align="left">
<asp:TextBox ID="txtAMCAddress" runat="server" CssClass="text_box" TextMode="MultiLine"
Rows="3"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator29" runat="server" CssClass="nor_txt"
ValidationGroup="AMC" SetFocusOnError="True" ErrorMessage="Address is required"
ControlToValidate="txtAMCAddress"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 147px" align="left">
<asp:Label ID="lblPanTan" runat="server" CssClass="nor_txt1" Text="PAN/TAN:"></asp:Label></td>
<td style="width: 460px" align="left">
<asp:TextBox ID="txtPanTan" runat="server" CssClass="text_box" ReadOnly="True"></asp:TextBox>
<asp:RequiredFieldValidator ID="RequiredFieldValidator30" runat="server" CssClass="nor_txt"
ValidationGroup="AMC" SetFocusOnError="True" ErrorMessage="PanTan is required"
ControlToValidate="txtPanTan"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 147px" align="left">
<asp:Label ID="lblStartDate" runat="server" CssClass="nor_txt1" Text="Start Date:"></asp:Label></td>
<td style="width: 460px" align="left">
<asp:TextBox ID="txtStartDate" runat="server" CssClass="text_box"></asp:TextBox> <asp:Image
ID="Img10" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop"
Height="18"></asp:Image>
<asp:RequiredFieldValidator ID="RequiredFieldValidator31" runat="server" CssClass="nor_txt"
ValidationGroup="AMC" SetFocusOnError="True" ErrorMessage="Start Date is required"
ControlToValidate="txtStartDate"></asp:RequiredFieldValidator>
</td>
</tr>
<tr>
<td style="width: 147px" align="left">
<asp:Label ID="lblEndDate" runat="server" CssClass="nor_txt1" Text="End Date:"></asp:Label></td>
<td style="width: 460px" align="left">
<asp:TextBox ID="txtEndDate" runat="server" CssClass="text_box"></asp:TextBox>
<asp:Image ID="Img11" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop"
Height="18"></asp:Image>
<asp:RequiredFieldValidator ID="RequiredFieldValidator32" runat="server" CssClass="nor_txt"
ValidationGroup="AMC" SetFocusOnError="True" ErrorMessage="End Date is required"
ControlToValidate="txtEndDate"></asp:RequiredFieldValidator><br />
<asp:CompareValidator ID="CompareValidator15" runat="server" CssClass="nor_txt" ValidationGroup="AMC"
SetFocusOnError="True" ErrorMessage="Start Date should be before End Date"
ControlToValidate="txtEndDate" Type="Date" Operator="GreaterThan" ControlToCompare="txtStartDate"></asp:CompareValidator></td>
</tr>
<tr>
<td style="height: 21px; text-align: center" align="left" colspan="2">
<asp:Button ID="btnAddServiceSchedule" OnClick="btnAddServiceSchedule_Click" runat="server"
CssClass="form_button_large" Text="Add Service Schedule"></asp:Button></td>
</tr>
<tr>
<td align="center" colspan="2">
<asp:Panel ID="pnlServiceSchedule" runat="server" Width="100%">
<br />
<asp:DataGrid ID="gvwServiceSchedule" runat="server" CssClass="tebale_border" ForeColor="Black"
Width="710px" Visible="False" OnItemCommand="gvwServiceSchedule_ItemCommand"
GridLines="None" CellPadding="2" BorderWidth="1px" AutoGenerateColumns="False">
<FooterStyle BackColor="Tan" />
<SelectedItemStyle BackColor="DarkSlateBlue" ForeColor="GhostWhite" />
<PagerStyle BackColor="PaleGoldenrod" ForeColor="DarkSlateBlue" HorizontalAlign="Center" />
<AlternatingItemStyle CssClass="alt_grid" />
<ItemStyle CssClass="nor_grid" />
<HeaderStyle CssClass="side_heading" HorizontalAlign="Center" />
<Columns>
<asp:BoundColumn DataField="SlNo" HeaderText="SlNo"></asp:BoundColumn>
<asp:TemplateColumn HeaderText="Service Date">
<ItemTemplate>
<input id="txtServiceDate" runat="server" class="text_box" readonly="readonly" type="text"
value='<%# DataBinder.Eval(Container.DataItem,"Service Date") %>' />
<asp:Image ID="ImgDateGrid" runat="server" Height="18" ImageAlign="TextTop" ImageUrl="date_picker.jpg"
Width="20" />
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txtServiceDate"
ErrorMessage="Service Date is mandatory" ValidationGroup="AMC">*</asp:RequiredFieldValidator>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn>
<ItemStyle HorizontalAlign="Center" />
<ItemTemplate>
<asp:Button ID="btnDelete" runat="server" CausesValidation="false" CommandName="Remove"
CssClass="form_button" Text="Remove" />
</ItemTemplate>
<HeaderStyle Width="100px" />
</asp:TemplateColumn>
</Columns>
</asp:DataGrid> </asp:Panel>
</td>
</tr>
<tr>
<td style="width: 147px" align="left">
<asp:Label ID="lblAttachment3" runat="server" CssClass="nor_txt1" Text="Attachment :"></asp:Label></td>
<td style="width: 460px" align="left">
<asp:FileUpload ID="fuAMC" runat="server" CssClass="text_box"></asp:FileUpload>
<asp:RequiredFieldValidator ID="RequiredFieldValidator34" runat="server" CssClass="nor_txt"
ValidationGroup="AMC" ErrorMessage="Attachment is required" ControlToValidate="fuAMC"></asp:RequiredFieldValidator></td>
</tr>
<tr>
<td style="width: 100%; text-align: left" colspan="2">
</td>
</tr>
</tbody>
</table>
<asp:Button ID="btnAddAMC" OnClick="btnAddAMC_Click" runat="server" CssClass="form_button"
Text="AddAMC" ValidationGroup="AMC"></asp:Button></td>
</tr>
</tbody>
</table>
</asp:Panel>
</td>
</tr>
</tbody>
</table>
</contenttemplate>
</asp:UpdatePanel>
</td>
</tr>
</table>
</asp:Content>


but working in this page,........

<%@. Page Language="C#" MasterPageFile="~/Master.master" AutoEventWireup="true" CodeFile="EditDocument.aspx.cs"
Inherits="EditDocument" %
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server"
<table border="0" cellpadding="0" cellspacing="0" width="100%">
<tr>
<td align="left" colspan="5" style="height: 28px" valign="middle">
<table border="0" cellpadding="0" cellspacing="0" style="height: 28px">
<tr>
<td id="tdAddProduct" runat="server" align="center" class="bg_tab_unselect" style="height: 28px"
valign="middle" width="129">
<a class="tab_unselect_text" href="http://links.10026.com/?link=AddDocument.aspx">Add Document</a></td>
<td id="tdblAdd" runat="server" align="center" style="height: 28px; width: 4px;" valign="middle">
<img height="10" src="http://pics.10026.com/?src=images/blank_w4.gif" width="4" /></td>
<td id="tdEditProduct" runat="server" align="center" class="bg_tab_select" style="height: 28px"
valign="middle" width="129">
<a class="tab_select_text" href="http://links.10026.com/?link=EditDocument.aspx">Edit Document</a></td>
<td align="center" style="height: 28px" valign="middle" width="4">
<img height="10" src="http://pics.10026.com/?src=images/blank_w4.gif" width="4" /></td>
<td id="tdViewProduct" runat="server" align="center" class="bg_tab_unselect" style="height: 28px"
valign="middle" width="129">
<a class="tab_unselect_text" href="http://links.10026.com/?link=ViewDocument.aspx">View Document</a></td>
<td align="center" style="height: 28px" valign="middle" width="4">
<img height="10" src="http://pics.10026.com/?src=images/blank_w4.gif" width="4" /></td>
</tr>
</table>
</td>
</tr>
<tr>
<td width="404" colspan="6" align="center" valign="middle" style="width: 100%;" class="tab_area">
<asp:ScriptManager id="ScriptManager1" runat="server">
</asp:ScriptManager
<asp:UpdatePanel id="UpdatePanel1" runat="server">
<Triggers>
<asp:PostBackTrigger ControlID="btnUpdateLeaseDeed" />
</Triggers>
<Triggers>
<asp:PostBackTrigger ControlID="lnkAttachLeaseDeed" />
</Triggers>
<Triggers>
<asp:PostBackTrigger ControlID="btnUpdateMotorInsurance" />
</Triggers>
<Triggers>
<asp:PostBackTrigger ControlID="lnkAttachMotor" />
</Triggers>
<Triggers>
<asp:PostBackTrigger ControlID="btnUpdateOfficeInsuranceTemplate" />
</Triggers>
<Triggers>
<asp:PostBackTrigger ControlID="lnkAttachOffice" />
</Triggers>
<Triggers>
<asp:PostBackTrigger ControlID="btnUpdateAMC" />
</Triggers>
<Triggers>
<asp:PostBackTrigger ControlID="lnkAttachAMC" />
</Triggers>
<contenttemplate>
<TABLE style="WIDTH: 800px" align=left><TBODY><TR><TD style="WIDTH: 100%" vAlign=middle align=center colSpan=6><asp:Label id="lblErrorMsg" runat="server" CssClass="nor_txt" ForeColor="Red"></asp:Label></TD></TR><TR><TD style="WIDTH: 100%" vAlign=middle align=left colSpan=6></TD></TR><TR><TD style="WIDTH: 100%" vAlign=middle align=center colSpan=6><asp:Panel id="pnlLeaseDeed" runat="server" Width="100%" Visible="false"><TABLE style="WIDTH: 100%" align=left><TBODY><TR><TD style="WIDTH: 100%; HEIGHT: 17px" class="side_heading" vAlign=middle align=center colSpan=6><asp:Label id="lblLeaseDeed" runat="server" Text="Lease Deed" __designer:wfdid="w153"></asp:Label></TD></TR><TR><TD style="WIDTH: 100%; HEIGHT: 812px" vAlign=middle align=center colSpan=6><TABLE style="WIDTH: 100%"><TBODY><TR><TD style="WIDTH: 150px" align=left><asp:Label id="lblLocation" runat="server" CssClass="nor_txt1" Text="Location:" __designer:wfdid="w154"></asp:Label></TD><TD style="WIDTH: 459px" align=left><asp:DropDownList id="ddlLocationLeaseDeed" runat="server" CssClass="text_box" __designer:wfdid="w155" AutoPostBack="True">
</asp:DropDownList></TD></TR><TR><TD style="WIDTH: 150px; TEXT-ALIGN: left"><asp:Label id="lblAddress" runat="server" CssClass="nor_txt1" Text="Address:" __designer:wfdid="w156"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtAddress" runat="server" CssClass="text_box" __designer:wfdid="w157" TextMode="MultiLine" Rows="3"></asp:TextBox> <asp:RequiredFieldValidator id="AddressRequiredFieldValidator" runat="server" CssClass="nor_txt" __designer:wfdid="w158" ValidationGroup="LeaseDeed" SetFocusOnError="True" ErrorMessage="Address is required" ControlToValidate="txtAddress">Address is required</asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 56px; TEXT-ALIGN: left"><asp:Label id="lblDetailsOfLandlord" runat="server" CssClass="nor_txt1" Text="Details Of Landlord :" __designer:wfdid="w159"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtDetailsOfLandlord" runat="server" CssClass="text_box" __designer:wfdid="w160" TextMode="MultiLine" Rows="3"></asp:TextBox> <asp:RequiredFieldValidator id="LandlordRequiredFieldValidator" runat="server" CssClass="nor_txt" __designer:wfdid="w161" ValidationGroup="LeaseDeed" ErrorMessage="LandLord Details is required" ControlToValidate="txtDetailsOfLandlord"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 150px; TEXT-ALIGN: left"><asp:Label id="lblTypeOfAgreement" runat="server" CssClass="nor_txt1" Text="Type Of Agreement:" __designer:wfdid="w162"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtTypeOfAgreement" runat="server" CssClass="text_box" __designer:wfdid="w163"></asp:TextBox> <asp:RequiredFieldValidator id="AgreeMentRequiredFieldValidator4" runat="server" CssClass="nor_txt" __designer:wfdid="w164" ValidationGroup="LeaseDeed" ErrorMessage="Type of Agreement is required" ControlToValidate="txtTypeOfAgreement"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px; TEXT-ALIGN: left"><asp:Label id="Label2" runat="server" CssClass="nor_txt1" Text="Tenure of Agreement:" __designer:wfdid="w165"></asp:Label></TD><TD style="HEIGHT: 22px" align=left><TABLE><TBODY><TR><TD style="WIDTH: 100px; HEIGHT: 22px"><asp:Label id="lblFromDate" runat="server" CssClass="nor_txt1" Text="From Date:" __designer:wfdid="w166"></asp:Label></TD><TD style="WIDTH: 296px; HEIGHT: 22px"><INPUT id="txtFromDate" class="text_box" readOnly type=text runat="server" /> <asp:Image id="Img1" runat="server" Width="20" __designer:wfdid="w167" ImageUrl="date_picker.jpg" ImageAlign="TextTop" Height="18"></asp:Image> <asp:RequiredFieldValidator id="FromDateRequiredFieldValidator" runat="server" CssClass="nor_txt" __designer:wfdid="w168" ValidationGroup="LeaseDeed" ErrorMessage="From Date is required" ControlToValidate="txtFromDate"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 100px"><asp:Label id="lblToDate" runat="server" CssClass="nor_txt1" Text="To Date:" __designer:wfdid="w169"></asp:Label></TD><TD style="WIDTH: 296px"><INPUT id="txtToDate" class="text_box" readOnly type=text runat="server" /> <asp:Image id="Img2" runat="server" Width="20" __designer:wfdid="w170" ImageUrl="date_picker.jpg" ImageAlign="TextTop" Height="18"></asp:Image> <asp:RequiredFieldValidator id="ToDateRequiredFieldValidator5" runat="server" CssClass="nor_txt" __designer:wfdid="w171" ValidationGroup="LeaseDeed" ErrorMessage="To Date is required" ControlToValidate="txtToDate"></asp:RequiredFieldValidator></TD></TR></TBODY></TABLE><asp:CompareValidator id="CompareValidator1" runat="server" CssClass="nor_txt" __designer:wfdid="w172" ValidationGroup="LeaseDeed" ErrorMessage="Tenure Of Agreement From Date should be before To Date" ControlToValidate="txtToDate" Type="Date" Operator="GreaterThan" ControlToCompare="txtFromDate"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px" align=left><asp:Label id="lnlMonths" runat="server" CssClass="nor_txt1" Text="Months:" __designer:wfdid="w173"></asp:Label></TD><TD style="HEIGHT: 22px" align=left><asp:TextBox id="txtMonths" runat="server" CssClass="text_box" __designer:wfdid="w174" ReadOnly="True"></asp:TextBox> <asp:Button id="BtnCalcMonth" onclick="BtnCalcMonth_Click" runat="server" CssClass="text_box" Text="calculate" __designer:wfdid="w175" BorderStyle="Inset"></asp:Button> <asp:Label id="lblErrorMonth" runat="server" CssClass="nor_txt" ForeColor="Red" __designer:wfdid="w176"></asp:Label></TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px" align=left><asp:Label id="lblArea" runat="server" CssClass="nor_txt1" Text="Super Area(Sq.Ft):" __designer:wfdid="w177"></asp:Label></TD><TD style="HEIGHT: 22px" align=left><asp:TextBox id="txtArea" runat="server" CssClass="text_box" __designer:wfdid="w178" AutoPostBack="True" OnTextChanged="txtCurrentRate_TextChanged"></asp:TextBox> <asp:RequiredFieldValidator id="AreaRequiredFieldValidator" runat="server" CssClass="nor_txt" __designer:wfdid="w179" ValidationGroup="LeaseDeed" ErrorMessage="Area is required" ControlToValidate="txtArea"></asp:RequiredFieldValidator> <asp:CompareValidator id="CompareValidator2" runat="server" CssClass="nor_txt" __designer:wfdid="w180" ValidationGroup="LeaseDeed" SetFocusOnError="True" ErrorMessage="Area Should be Numeric" ControlToValidate="txtArea" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px" align=left><asp:Label id="lblCurrentRent" runat="server" CssClass="nor_txt1" Text="Current Rent(Rs):" __designer:wfdid="w181"></asp:Label></TD><TD style="HEIGHT: 22px" align=left><asp:TextBox id="txtCurrentRate" runat="server" CssClass="text_box" __designer:wfdid="w182" AutoPostBack="True" OnTextChanged="txtCurrentRate_TextChanged"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator4" runat="server" CssClass="nor_txt" __designer:wfdid="w183" ValidationGroup="LeaseDeed" ErrorMessage="Current Rent is required" ControlToValidate="txtCurrentRate"></asp:RequiredFieldValidator> <asp:CompareValidator id="CompareValidator3" runat="server" CssClass="nor_txt" __designer:wfdid="w184" ValidationGroup="LeaseDeed" SetFocusOnError="True" ErrorMessage="Current Rent Should be Numeric" ControlToValidate="txtCurrentRate" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 150px" align=left><asp:Label id="lblRate" runat="server" CssClass="nor_txt1" Text="Rate:" __designer:wfdid="w185"></asp:Label></TD><TD align=left><asp:TextBox id="txtRate" runat="server" CssClass="text_box" __designer:wfdid="w186" ReadOnly="True"></asp:TextBox> </TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 8px" align=left><asp:Label id="lblEscalation" runat="server" CssClass="nor_txt1" Text="Escalations:" __designer:wfdid="w187"></asp:Label></TD><TD style="WIDTH: 429px; HEIGHT: 8px" align=left></TD></TR><TR><TD style="HEIGHT: 29px" align=center colSpan=2><asp:Button id="btnEditEscalation" onclick="btnEditEscalation_Click" runat="server" CssClass="form_button_large" Text="Add Escalation" __designer:wfdid="w188"></asp:Button></TD></TR><TR><TD align=center colSpan=2><asp:Panel id="pnlEscalation" runat="server" Width="100%" __designer:wfdid="w189"><asp:DataGrid id="gvwEscalation" runat="server" CssClass="tebale_border" ForeColor="Black" Width="750px" Visible="False" HorizontalAlign="Center" __designer:wfdid="w190" OnItemCommand="gvwEscalation_ItemCommand" GridLines="None" CellPadding="2" BorderWidth="1px" AutoGenerateColumns="False">
<FooterStyle BackColor="Tan" />
<SelectedItemStyle BackColor="DarkSlateBlue" ForeColor="GhostWhite" />
<PagerStyle BackColor="PaleGoldenrod" ForeColor="DarkSlateBlue" HorizontalAlign="Center" />
<AlternatingItemStyle CssClass="alt_grid" />
<ItemStyle CssClass="nor_grid" />
<HeaderStyle CssClass="side_heading" HorizontalAlign="Center" />
<Columns>
<asp:BoundColumn DataField="SlNo" HeaderText="SlNo"></asp:BoundColumn>
<asp:TemplateColumn HeaderText="EscalationId" Visible="False">
<ItemTemplate>
<asp:TextBox ID="txtEscalationId" runat="server" CssClass="text_box" Text='<%# DataBinder.Eval(Container.DataItem,"EscalationId") %>'
Visible="false" Width="120px"></asp:TextBox>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="Amount">
<ItemTemplate>
<asp:TextBox ID="txtAmount" runat="server" CssClass="text_box" Text='<%# DataBinder.Eval(Container.DataItem,"Amount") %>'
Width="120px"></asp:TextBox><asp:RequiredFieldValidator ID="RequiredFieldValidator1"
runat="server" ControlToValidate="txtAmount" ErrorMessage="Amount is mandatory"
ValidationGroup="LeaseDeed">*</asp:RequiredFieldValidator>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="From Date">
<ItemTemplate>
<input id="txtFromDateGrid" runat="server" class="text_box" readonly="readonly" size="20"
type="text" value='<%# DataBinder.Eval(Container.DataItem,"From Date") %>' />
<asp:Image ID="ImgFromDateGrid" runat="server" Height="18" ImageAlign="TextTop" ImageUrl="date_picker.jpg"
Width="20" />
<asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="txtFromDateGrid"
ErrorMessage="From Date is mandatory" ValidationGroup="LeaseDeed">*</asp:RequiredFieldValidator>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn HeaderText="To Date">
<ItemTemplate>
<input id="txtToDateGrid" runat="server" class="text_box" readonly="readonly" type="text"
value='<%# DataBinder.Eval(Container.DataItem,"To Date") %>' />
<asp:Image ID="ImgToDate" runat="server" Height="18" ImageAlign="TextTop" ImageUrl="date_picker.jpg"
Width="20" />
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="txtToDateGrid"
ErrorMessage="To Date is mandatory" ValidationGroup="LeaseDeed">*</asp:RequiredFieldValidator>
<asp:CompareValidator ID="CompareValidatorDate" runat="server" ControlToCompare="txtFromDateGrid"
ControlToValidate="txtToDateGrid" CssClass="nor_txt" ErrorMessage="StartDate>EndDate"
Operator="GreaterThan" ValidationGroup="LeaseDeed"></asp:CompareValidator>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn>
<ItemStyle HorizontalAlign="Center" />
<ItemTemplate>
<asp:Button ID="btnDelete" runat="server" CausesValidation="false" CommandName="Remove"
CssClass="form_button" Text="Remove" />
</ItemTemplate>
<HeaderStyle Width="100px" />
</asp:TemplateColumn>
</Columns>
</asp:DataGrid> </asp:Panel> </TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px; TEXT-ALIGN: left" align=left><asp:Label id="lblAdvanceRentals" runat="server" CssClass="nor_txt1" Text="Advance Rentals(Rs):" __designer:wfdid="w191"></asp:Label></TD><TD style="WIDTH: 429px; HEIGHT: 22px" align=left><asp:TextBox id="txtAdvanceRentals" runat="server" CssClass="text_box" __designer:wfdid="w192"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator5" runat="server" CssClass="nor_txt" __designer:wfdid="w193" ValidationGroup="LeaseDeed" ErrorMessage="Advance is required" ControlToValidate="txtAdvanceRentals"></asp:RequiredFieldValidator> <asp:CompareValidator id="CompareValidator4" runat="server" CssClass="nor_txt" __designer:wfdid="w194" ValidationGroup="LeaseDeed" SetFocusOnError="True" ErrorMessage="Advance Rentals Should be Numeric" ControlToValidate="txtAdvanceRentals" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px; TEXT-ALIGN: left"><asp:Label id="lblDeposit" runat="server" CssClass="nor_txt1" Text="Deposit:" __designer:wfdid="w195"></asp:Label></TD><TD style="WIDTH: 429px; HEIGHT: 22px" align=left><asp:TextBox id="txtDeposit" runat="server" CssClass="text_box" __designer:wfdid="w196"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator6" runat="server" CssClass="nor_txt" __designer:wfdid="w197" ValidationGroup="LeaseDeed" ErrorMessage="Deposit is required" ControlToValidate="txtDeposit"></asp:RequiredFieldValidator> <asp:CompareValidator id="CompareValidator5" runat="server" CssClass="nor_txt" __designer:wfdid="w198" ValidationGroup="LeaseDeed" ErrorMessage="Deposit Should be Numeric" ControlToValidate="txtDeposit" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px" align=left><asp:Label id="lblLockInPeriod" runat="server" CssClass="nor_txt1" Text="Lock-in Period:" __designer:wfdid="w199"></asp:Label> </TD><TD style="HEIGHT: 22px" align=left><TABLE><TBODY><TR><TD style="WIDTH: 100px; HEIGHT: 22px"><asp:Label id="lblMonth" runat="server" CssClass="nor_txt1" Text="Month:" __designer:wfdid="w200"></asp:Label></TD><TD style="WIDTH: 410px; HEIGHT: 22px"><asp:DropDownList id="ddlMonth" runat="server" CssClass="text_box" __designer:wfdid="w201">
</asp:DropDownList> </TD></TR><TR><TD style="WIDTH: 100px"><asp:Label id="lblDate" runat="server" CssClass="nor_txt1" Text="Date:" __designer:wfdid="w202"></asp:Label></TD><TD style="WIDTH: 410px"><INPUT id="txtLocInDate" class="text_box" readOnly type=text runat="server" /> <asp:Image id="Img4" runat="server" Width="20" __designer:wfdid="w203" ImageUrl="date_picker.jpg" ImageAlign="TextTop" Height="18"></asp:Image> <asp:RequiredFieldValidator id="RequiredFieldValidator8" runat="server" CssClass="nor_txt" __designer:wfdid="w204" ValidationGroup="LeaseDeed" ErrorMessage="Date is required" ControlToValidate="txtLocInDate"></asp:RequiredFieldValidator></TD></TR></TBODY></TABLE></TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px" align=left><asp:Label id="lblNoticePeriod" runat="server" CssClass="nor_txt1" Text="Notice Period:" __designer:wfdid="w205"></asp:Label></TD><TD style="WIDTH: 429px; HEIGHT: 22px" align=left><asp:TextBox id="txtNoticePeriod" runat="server" CssClass="text_box" __designer:wfdid="w206"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator9" runat="server" CssClass="nor_txt" __designer:wfdid="w207" ValidationGroup="LeaseDeed" ErrorMessage="Notice period is required" ControlToValidate="txtNoticePeriod"></asp:RequiredFieldValidator> <asp:CompareValidator id="CompareValidator7" runat="server" CssClass="nor_txt" __designer:wfdid="w208" ValidationGroup="LeaseDeed" ErrorMessage="Notice Period Should be integer" ControlToValidate="txtNoticePeriod" Type="Integer" Operator="DataTypeCheck" ValueToCompare="10"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px" align=left><asp:Label id="lblAttachment1" runat="server" CssClass="nor_txt1" Text="Attachment :" __designer:wfdid="w209"></asp:Label></TD><TD style="WIDTH: 429px; HEIGHT: 22px" align=left><asp:FileUpload id="fuLeaseDeed" runat="server" CssClass="text_box" __designer:wfdid="w210"></asp:FileUpload> <asp:LinkButton id="lnkAttachLeaseDeed" onclick="lnkAttachLeaseDeed_Click" runat="server" CssClass="lnk_txt" __designer:wfdid="w211">View Uploaded Document</asp:LinkButton> </TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px" align=left><asp:Label id="lblRemarksLeaseDeed" runat="server" CssClass="nor_txt1" Text="Remarks :" __designer:wfdid="w212"></asp:Label></TD><TD style="WIDTH: 429px; HEIGHT: 22px" align=left><asp:TextBox id="txtRemarksLeaseDeed" runat="server" CssClass="text_box" __designer:wfdid="w213" TextMode="MultiLine" Rows="3"></asp:TextBox></TD></TR></TBODY></TABLE></TD></TR><TR><TD style="WIDTH: 100%; HEIGHT: 54px" vAlign=middle align=center colSpan=6><TABLE style="WIDTH: 100%"><TBODY><TR><TD style="HEIGHT: 29px" align=center colSpan=2><asp:Button id="btnUpdateLeaseDeed" onclick="btnUpdateLeaseDeed_Click" runat="server" CssClass="form_button_large" Text="Update Lease Deed" __designer:wfdid="w214" ValidationGroup="LeaseDeed"></asp:Button><asp:Button id="btnCloseLeaseDeed" runat="server" CausesValidation="false" CssClass="form_button" Text="Close" __designer:wfdid="w215" PostBackUrl="~/ViewDocument.aspx"></asp:Button></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></asp:Panel> </TD></TR><TR style="FONT-SIZE: 12pt; FONT-FAMILY: Times New Roman"><TD style="WIDTH: 100%" vAlign=middle align=left colSpan=6><asp:Panel id="pnlMotorInsurance" runat="server" Width="100%" Visible="false"> <TABLE style="WIDTH: 100%" align=left><TBODY><TR><TD style="WIDTH: 100%" vAlign=middle align=center colSpan=6><TABLE style="WIDTH: 100%"><TBODY><TR><TD class="side_heading" align=center colSpan=2><asp:Label id="lblMotorInsurance" runat="server" Text="Motor Insurance"></asp:Label></TD></TR><TR><TD style="WIDTH: 147px; HEIGHT: 22px" align=left colSpan=1><asp:Label id="Label3" runat="server" CssClass="nor_txt1" Text="Location:"></asp:Label></TD><TD style="HEIGHT: 22px" align=left><asp:DropDownList id="ddlLocationMotorInsurance" runat="server" CssClass="text_box" AutoPostBack="True">
</asp:DropDownList></TD></TR><TR><TD style="WIDTH: 147px" align=left colSpan=1><asp:Label id="lblVehicleNo" runat="server" CssClass="nor_txt1" Text="Vehicle No:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtVehicleNo" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator14" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Vehicle No. is required" ControlToValidate="txtVehicleNo"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 147px" align=left colSpan=1><asp:Label id="lblModel" runat="server" CssClass="nor_txt1" Text="Model:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtModel" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator15" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Model is required" ControlToValidate="txtModel"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 147px" align=left colSpan=1><asp:Label id="lblCapacity" runat="server" CssClass="nor_txt1" Text="Capacity:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtCapacity" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator16" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Capacity is required" ControlToValidate="txtCapacity"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 147px" align=left colSpan=1><asp:Label id="lblDateOfPurchase" runat="server" CssClass="nor_txt1" Text="Date Of Purchase:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><INPUT id="txtDateOfPurchase" class="text_box" readOnly type=text runat="server" /> <asp:Image id="Img5" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop" Height="18"></asp:Image> <asp:RequiredFieldValidator id="RequiredFieldValidator10" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" ErrorMessage="Date of Purchase is required" ControlToValidate="txtDateOfPurchase"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 147px; HEIGHT: 22px" align=left colSpan=1><asp:Label id="lblPurchaseValue" runat="server" CssClass="nor_txt1" Text="Purchase Value:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtPurchaseValue" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator17" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Purchase Value is required" ControlToValidate="txtPurchaseValue"></asp:RequiredFieldValidator> <asp:CompareValidator id="CompareValidator8" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Purchase Value Should be Numeric" ControlToValidate="txtPurchaseValue" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 147px; HEIGHT: 22px" align=left colSpan=1><asp:Label id="lblUserName" runat="server" CssClass="nor_txt1" Text="User Name:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtUserName" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator18" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="User Name is required" ControlToValidate="txtUserName"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 147px" align=left colSpan=1><asp:Label id="lblPolicyNo" runat="server" CssClass="nor_txt1" Text="Policy No:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtPolicyNo" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator19" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Policy No. is required" ControlToValidate="txtPolicyNo"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 147px; HEIGHT: 32px" align=left colSpan=1><asp:Label id="lblNameOfInsuranceCompany" runat="server" CssClass="nor_txt1" Width="162px" Text="Name Of Insurance Company:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtNameOfInsuranceCompany" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator20" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Name Of Insurance Company is required" ControlToValidate="txtNameOfInsuranceCompany"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 147px" align=left colSpan=1><asp:Label id="lblRenewalDated" runat="server" CssClass="nor_txt1" Text="Renewal Dated:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><INPUT id="txtRenewalDated" class="text_box" readOnly type=text runat="server" /> <asp:Image id="Img6" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop" Height="18"></asp:Image> <asp:RequiredFieldValidator id="RequiredFieldValidator11" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" ErrorMessage="Renewal Date is required" ControlToValidate="txtRenewalDated"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 147px" align=left colSpan=1><asp:Label id="lblExpiry" runat="server" CssClass="nor_txt1" Text="Expiry:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><INPUT id="txtExpiry" class="text_box" readOnly type=text runat="server" /> <asp:Image id="Image1" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop" Height="18"></asp:Image> <asp:RequiredFieldValidator id="RequiredFieldValidator7" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" ErrorMessage="Expiry Date is required" ControlToValidate="txtExpiry"></asp:RequiredFieldValidator><BR /><asp:CompareValidator id="CompareValidator11" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" ErrorMessage="Expiry Date should be after Renewal Date" ControlToValidate="txtExpiry" Type="Date" Operator="GreaterThan" ControlToCompare="txtRenewalDated"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 147px" align=left colSpan=1><asp:Label id="lblPremiumAmount" runat="server" CssClass="nor_txt1" Text="Premium Amount:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtPremiumAmount" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator21" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Premium Amount is required" ControlToValidate="txtPremiumAmount"></asp:RequiredFieldValidator> <asp:CompareValidator id="CompareValidator9" runat="server" CssClass="nor_txt" Width="174px" ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Premium Amount Should be Numeric" ControlToValidate="txtPremiumAmount" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 147px" align=left colSpan=1><asp:Label id="lblInsuredAmount" runat="server" CssClass="nor_txt1" Text="Insured Amount:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtInsuredAmount" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator22" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Insured Amount is required" ControlToValidate="txtInsuredAmount"></asp:RequiredFieldValidator> <asp:CompareValidator id="CompareValidator10" runat="server" CssClass="nor_txt" Width="176px" ValidationGroup="MotorInsurance" SetFocusOnError="True" ErrorMessage="Insured Amount Should be Numeric" ControlToValidate="txtInsuredAmount" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 147px" align=left colSpan=1><asp:Label id="lblAttachment2" runat="server" CssClass="nor_txt1" Text="Attachment :"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:FileUpload id="fuMotor" runat="server" CssClass="text_box"></asp:FileUpload> <asp:LinkButton id="lnkAttachMotor" onclick="lnkAttachMotor_Click" runat="server" CssClass="lnk_txt">View Uploaded Document</asp:LinkButton> </TD></TR><TR><TD style="WIDTH: 147px" align=left colSpan=1><asp:Label id="lblRemarksMotorInsurance" runat="server" CssClass="nor_txt1" Text="Remarks :"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtRemarksMotornsurance" runat="server" CssClass="text_box" TextMode="MultiLine" Rows="3"></asp:TextBox></TD></TR></TBODY></TABLE></TD></TR><TR><TD style="WIDTH: 100%; HEIGHT: 29px" vAlign=middle align=center colSpan=6><TABLE style="WIDTH: 100%"><TBODY><TR><TD style="TEXT-ALIGN: center" colSpan=2><asp:Button id="btnUpdateMotorInsurance" onclick="btnUpdateMotorInsurance_Click" runat="server" CssClass="form_button_large" Text="Update Motor Insurance" ValidationGroup="MotorInsurance"></asp:Button><asp:Button id="btnCloseMotorInsurance" runat="server" CausesValidation="false" CssClass="form_button" Text="Close" PostBackUrl="~/ViewDocument.aspx"></asp:Button></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></asp:Panel> </TD></TR><TR style="FONT-SIZE: 12pt; FONT-FAMILY: Times New Roman"><TD style="WIDTH: 100%" vAlign=middle align=left colSpan=6><asp:Panel id="pnlOfficeInsurance" runat="server" Width="100%" Visible="false"><TABLE style="WIDTH: 100%" align=left><TBODY><TR><TD style="WIDTH: 100%" class="side_heading" vAlign=middle align=center colSpan=6><asp:Label id="lblOfficeInsurance" runat="server" Text="Office Insurance"></asp:Label></TD></TR><TR><TD style="WIDTH: 100%" vAlign=middle align=center colSpan=6><TABLE style="WIDTH: 100%"><TBODY><TR><TD style="WIDTH: 150px" align=left><asp:Label id="Label5" runat="server" CssClass="nor_txt1" Text="Location:"></asp:Label></TD><TD style="WIDTH: 459px" align=left><asp:DropDownList id="ddlLocationAddOfficeInsurance" runat="server" CssClass="text_box" AutoPostBack="True">
</asp:DropDownList></TD></TR><TR><TD style="WIDTH: 150px" align=left><asp:Label id="Label6" runat="server" CssClass="nor_txt1" Text="Policy No:"></asp:Label></TD><TD style="WIDTH: 429px; HEIGHT: 21px" align=left><asp:TextBox id="txtPolicyNoInsurance" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator23" runat="server" CssClass="nor_txt" ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Policy No. is required" ControlToValidate="txtPolicyNoInsurance"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 150px" align=left><asp:Label id="lblDateOfIssue" runat="server" CssClass="nor_txt1" Text="Date Of Issue:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><INPUT id="txtDateOfIssue" class="text_box" readOnly type=text runat="server" /> <asp:Image id="Img8" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop" Height="18"></asp:Image> <asp:RequiredFieldValidator id="RequiredFieldValidator13" runat="server" CssClass="nor_txt" ValidationGroup="OfficeInsurance" ErrorMessage="Date of Issue is required" ControlToValidate="txtDateOfIssue"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 150px" align=left><asp:Label id="Label7" runat="server" CssClass="nor_txt1" Width="166px" Text="Name Of Insurance Company:"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtOfficeInsuranceCompany" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator24" runat="server" CssClass="nor_txt" ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Name Of Insurance Company is required" ControlToValidate="txtOfficeInsuranceCompany"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px" align=left><asp:Label id="lblNatureOfPolicy" runat="server" CssClass="nor_txt1" Text="Nature Of Policy:"></asp:Label></TD><TD style="WIDTH: 429px; HEIGHT: 22px" align=left><asp:TextBox id="txtNatureOfPolicy" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator25" runat="server" CssClass="nor_txt" ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Nature Of Policy is required" ControlToValidate="txtNatureOfPolicy"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px; TEXT-ALIGN: left" align=left><asp:Label id="lblExpiryDate" runat="server" CssClass="nor_txt1" Text="Expiry Date:"></asp:Label> </TD><TD style="WIDTH: 429px" id="txtExpiryDate" align=left><INPUT id="txtExpiryDate" class="text_box" readOnly type=text runat="server" /> <asp:Image id="Img9" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop" Height="18"></asp:Image> <asp:RequiredFieldValidator id="RequiredFieldValidator12" runat="server" CssClass="nor_txt" ValidationGroup="MotorInsurance" ErrorMessage="Expiry Date is required" ControlToValidate="txtExpiryDate"></asp:RequiredFieldValidator><BR /><asp:CompareValidator id="CompareValidator14" runat="server" CssClass="nor_txt" ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Date of issue should be before Expairy Date" ControlToValidate="txtExpiryDate" Type="Date" Operator="GreaterThan" ControlToCompare="txtDateOfIssue"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 150px" align=left><asp:Label id="Label8" runat="server" CssClass="nor_txt1" Text="Insured Amount:"></asp:Label> </TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtOfficeInsuranceAmount" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator27" runat="server" CssClass="nor_txt" ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Premium Amount is required" ControlToValidate="txtOfficeInsuranceAmount"></asp:RequiredFieldValidator><BR /><asp:CompareValidator id="CompareValidator12" runat="server" CssClass="nor_txt" Width="174px" ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Premium Amount Should be Numeric" ControlToValidate="txtPremiumAmountOffice" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 150px" align=left><asp:Label id="Label9" runat="server" CssClass="nor_txt1" Text="Premium Amount:"></asp:Label> </TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtPremiumAmountOffice" runat="server" CssClass="text_box"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator28" runat="server" CssClass="nor_txt" ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Insured Amount is required" ControlToValidate="txtPremiumAmountOffice"></asp:RequiredFieldValidator> <BR /><asp:CompareValidator id="CompareValidator13" runat="server" CssClass="nor_txt" Width="176px" ValidationGroup="OfficeInsurance" SetFocusOnError="True" ErrorMessage="Insured Amount Should be Numeric" ControlToValidate="txtPremiumAmountOffice" Type="Double" Operator="DataTypeCheck"></asp:CompareValidator></TD></TR><TR><TD style="WIDTH: 150px; HEIGHT: 22px" align=left><asp:Label id="lblAttachment3" runat="server" CssClass="nor_txt1" Text="Attachment :"></asp:Label></TD><TD style="WIDTH: 429px; HEIGHT: 22px" align=left><asp:FileUpload id="fuOffice" runat="server" CssClass="text_box"></asp:FileUpload> <asp:LinkButton id="lnkAttachOffice" onclick="lnkAttachOffice_Click" runat="server" CssClass="lnk_txt" ValidationGroup="OfficeInsurance">View Uploaded Document</asp:LinkButton> </TD></TR><TR><TD style="WIDTH: 150px" align=left><asp:Label id="lblRemarksOfficeInsurance" runat="server" CssClass="nor_txt1" Text="Remarks :"></asp:Label></TD><TD style="WIDTH: 429px" align=left><asp:TextBox id="txtRemarksOfficeInsurance" runat="server" CssClass="text_box" TextMode="MultiLine" Rows="3"></asp:TextBox></TD></TR></TBODY></TABLE></TD></TR><TR><TD style="WIDTH: 100%" vAlign=middle align=center colSpan=6><TABLE style="WIDTH: 100%"><TBODY><TR><TD style="TEXT-ALIGN: center" colSpan=2><asp:Button id="btnUpdateOfficeInsuranceTemplate" onclick="btnUpdateOfficeInsuranceTemplate_Click" runat="server" CssClass="form_button_large" Text="Update Office Insurance" ValidationGroup="OfficeInsurance"></asp:Button><asp:Button id="btnCloseOfficeInsurance" runat="server" CausesValidation="false" CssClass="form_button" Text="Close" PostBackUrl="~/ViewDocument.aspx"></asp:Button></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></asp:Panel> </TD></TR><TR style="FONT-SIZE: 12pt; FONT-FAMILY: Times New Roman"><TD style="WIDTH: 100%" vAlign=middle align=left colSpan=6><asp:Panel id="pnlAMC" runat="server" Width="100%" Visible="false" HorizontalAlign="Center"><TABLE style="WIDTH: 100%" align=left><TBODY><TR><TD style="WIDTH: 100%; HEIGHT: 17px; TEXT-ALIGN: center" class="side_heading" vAlign=middle align=center colSpan=6><asp:Label id="lblAMC" runat="server" Text="AMC"></asp:Label></TD></TR><TR><TD style="WIDTH: 100%; TEXT-ALIGN: center" vAlign=middle align=center colSpan=6><TABLE style="WIDTH: 100%"><TBODY><TR><TD style="WIDTH: 147px; HEIGHT: 22px" align=left><asp:Label id="lblVendorName" runat="server" CssClass="nor_txt1" Text="VendorName:"></asp:Label></TD><TD style="WIDTH: 460px; HEIGHT: 22px" align=left><asp:DropDownList id="ddlVendorName" runat="server" CssClass="text_box" AutoPostBack="True" OnSelectedIndexChanged="ddlVendorName_SelectedindexChanged">
<asp:ListItem>Vendor Name2</asp:ListItem>
<asp:ListItem>Vendor Name1</asp:ListItem>
</asp:DropDownList></TD></TR><TR><TD style="WIDTH: 147px" align=left><asp:Label id="Label11" runat="server" CssClass="nor_txt1" Text="Address:"></asp:Label></TD><TD style="WIDTH: 460px" align=left><asp:TextBox id="txtAMCAddress" runat="server" CssClass="text_box" TextMode="MultiLine" Rows="3"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator29" runat="server" CssClass="nor_txt" ValidationGroup="AMC" SetFocusOnError="True" ErrorMessage="Address is required" ControlToValidate="txtAMCAddress"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 147px" align=left><asp:Label id="lblPanTan" runat="server" CssClass="nor_txt1" Text="PAN/TAN:"></asp:Label></TD><TD style="WIDTH: 460px" align=left><asp:TextBox id="txtPanTan" runat="server" CssClass="text_box" ReadOnly="True"></asp:TextBox> <asp:RequiredFieldValidator id="RequiredFieldValidator30" runat="server" CssClass="nor_txt" ValidationGroup="AMC" SetFocusOnError="True" ErrorMessage="PanTan is required" ControlToValidate="txtPanTan"></asp:RequiredFieldValidator></TD></TR><TR><TD style="WIDTH: 147px" align=left><asp:Label id="lblStartDate" runat="server" CssClass="nor_txt1" Text="Start Date:"></asp:Label></TD><TD style="WIDTH: 460px" align=left><asp:TextBox id="txtStartDate" runat="server" CssClass="text_box"></asp:TextBox> <asp:Image id="Img10" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop" Height="18"></asp:Image> <asp:RequiredFieldValidator id="RequiredFieldValidator31" runat="server" CssClass="nor_txt" ValidationGroup="AMC" SetFocusOnError="True" ErrorMessage="Start Date is required" ControlToValidate="txtStartDate"></asp:RequiredFieldValidator> </TD></TR><TR><TD style="WIDTH: 147px" align=left><asp:Label id="lblEndDate" runat="server" CssClass="nor_txt1" Text="End Date:"></asp:Label></TD><TD style="WIDTH: 460px" align=left><asp:TextBox id="txtEndDate" runat="server" CssClass="text_box"></asp:TextBox> <asp:Image id="Img11" runat="server" Width="20" ImageUrl="date_picker.jpg" ImageAlign="TextTop" Height="18"></asp:Image> <asp:RequiredFieldValidator id="RequiredFieldValidator32" runat="server" CssClass="nor_txt" ValidationGroup="AMC" SetFocusOnError="True" ErrorMessage="End Date is required" ControlToValidate="txtEndDate"></asp:RequiredFieldValidator><BR /><asp:CompareValidator id="CompareValidator15" runat="server" CssClass="nor_txt" ValidationGroup="AMC" SetFocusOnError="True" ErrorMessage="Start Date should be before End Date" ControlToValidate="txtEndDate" Type="Date" Operator="GreaterThan" ControlToCompare="txtStartDate"></asp:CompareValidator></TD></TR><TR><TD style="HEIGHT: 21px; TEXT-ALIGN: center" align=left colSpan=2><asp:Button id="EditAddServiceSchedule" onclick="btnEditServiceSchedule_Click" runat="server" CssClass="form_button_large" Text="Add Service Schedule"></asp:Button></TD></TR><TR><TD style="HEIGHT: 235px" align=center colSpan=2><asp:Panel id="pnlServiceSchedule" runat="server" Width="100%"><BR /><asp:DataGrid id="gvwServiceSchedule" runat="server" CssClass="tebale_border" ForeColor="Black" Width="710px" Visible="False" OnItemCommand="gvwServiceSchedule_ItemCommand" GridLines="None" CellPadding="2" BorderWidth="1px" AutoGenerateColumns="False">
<FooterStyle BackColor="Tan"></FooterStyle
<SelectedItemStyle BackColor="DarkSlateBlue" ForeColor="GhostWhite"></SelectedItemStyle
<PagerStyle BackColor="PaleGoldenrod" ForeColor="DarkSlateBlue" HorizontalAlign="Center"></PagerStyle
<AlternatingItemStyle CssClass="alt_grid"></AlternatingItemStyle
<ItemStyle CssClass="nor_grid"></ItemStyle
<HeaderStyle CssClass="side_heading" HorizontalAlign="Center"></HeaderStyle>
<Columns>
<asp:BoundColumn DataField="SlNo" HeaderText="SlNo"></asp:BoundColumn>
<asp:TemplateColumn HeaderText="Service Date"><ItemTemplate>
<INPUT id="txtServiceDate" class="text_box" readOnly type=text value='<%# DataBinder.Eval(Container.DataItem,"Service Date") %>' runat="server" /> <asp:Image id="ImgDateGrid" runat="server" Width="20" __designer:wfdid="w95" ImageUrl="date_picker.jpg" ImageAlign="TextTop" Height="18"></asp:Image> <asp:RequiredFieldValidator id="RequiredFieldValidator1" runat="server" __designer:wfdid="w96" ValidationGroup="AMC" ErrorMessage="Service Date is mandatory" ControlToValidate="txtServiceDate">*</asp:RequiredFieldValidator>
</ItemTemplate>
</asp:TemplateColumn>
<asp:TemplateColumn>
<ItemStyle HorizontalAlign="Center"></ItemStyle>
<ItemTemplate>
<asp:Button ID="btnDelete" runat="server" CausesValidation="false" CommandName="Remove"
CssClass="form_button" Text="Remove" />

</ItemTemplate
<HeaderStyle Width="100px"></HeaderStyle>
</asp:TemplateColumn>
</Columns>
</asp:DataGrid> </asp:Panel> </TD></TR><TR><TD style="WIDTH: 147px" align=left><asp:Label id="lblAttachment4" runat="server" CssClass="nor_txt1" Text="Attachment :"></asp:Label></TD><TD style="WIDTH: 460px" align=left><asp:FileUpload id="fuAMC" runat="server" CssClass="text_box"></asp:FileUpload> <asp:LinkButton id="lnkAttachAMC" onclick="lnkAttachAMC_Click" runat="server" CssClass="lnk_txt">View Uploaded Document</asp:LinkButton> </TD></TR><TR><TD style="WIDTH: 147px" align=left><asp:Label id="lblRemarksAMC" runat="server" CssClass="nor_txt1" Text="Remarks :"></asp:Label></TD><TD style="WIDTH: 460px" align=left><asp:TextBox id="txtRemarksAMC" runat="server" CssClass="text_box" TextMode="MultiLine" Rows="3"></asp:TextBox></TD></TR><TR><TD style="WIDTH: 100%; TEXT-ALIGN: left" colSpan=2></TD></TR></TBODY></TABLE><TABLE style="WIDTH: 100%"><TBODY><TR><TD style="HEIGHT: 29px; TEXT-ALIGN: center" colSpan=2><asp:Button id="btnUpdateAMC" onclick="btnUpdateAMC_Click" runat="server" CssClass="form_button" Text="Update AMC" ValidationGroup="AMC"></asp:Button><asp:Button id="btnCloseAMC" runat="server" CausesValidation="false" CssClass="form_button" Text="Close" PostBackUrl="~/ViewDocument.aspx"></asp:Button></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></asp:Panel> </TD></TR></TBODY></TABLE>
</contenttemplate>
</asp:UpdatePanel>
</td>
</tr>
</table>
</asp:Content>


Hi there

I also had the same problem. My File Upload control was not working properly in Update pannel.i was uploading multiple files and for this purpose i used different upload button which was in the same update pannel . i was using upload pannel in a tab container . and in each tab there was an update pannel. I simply removed that update pannel in which there was File Upload control. This thing posts back the whole pageSad. but uploads the file. If any one else has the solution then kindly share it.


Hi

An Ajax Alternative for FileUpload:

We've all embraced Ajax as a revolutionary technology, but many of us forget (or are not aware) of asynchronous posts in the times before XmlHttp requests. Our good old friend the IFrame used to be the preferred option for asynchronous http communications. Because an iframe is in essence it's own browser window, it can be used to fire off asynchronous requests (both POST and GET). However, even more important is an IFrame's ability to be a 'target' of a form POST. By adding an IFrame to the page and setting it as the target of the form post, you can in essence create an asynchronous file transfer.

For more help about Ajax Alternative for FileUpload, Please check: http://blogs.infragistics.com/blogs/tony_lombardo/archive/2007/04/09/file-uploads-where-s-the-ajax.aspx

A good example for you:http://forums.asp.net/t/1117746.aspx

NOTE:This response contains a reference to a third party World Wide Web site. Microsoft is providing this information as a convenience to you. Microsoft does not control these sites and has not tested any software or information found on these sites; therefore, Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. There are inherent dangers in the use of any software found on the Internet, and Microsoft cautions you to make sure that you completely understand the risk before retrieving any software from the Internet.

No comments:

Post a Comment