Using RegisterClientScriptBlock I have no problem whith displaying the warning alert but after I close the pop up the binding becomes a real mess. The weird thing is that when I try to debug it and go with F10 the binding is ok.
This this a code behind method:
protected void lvContratFonds_OnItemDeleting(object source, ListViewDeleteEventArgs e)
{
try
{
ListView lv = (ListView)source;
int contratId = int.Parse(((HiddenField)lv.Parent.FindControl("hdnContratId")).Value);
int anneeFiscaleId = int.Parse(((HiddenField)lv.Items[e.ItemIndex].FindControl("hdnAnneeFiscaleId")).Value);
int contratFondId = int.Parse(((HiddenField)lv.Items[e.ItemIndex].FindControl("hdnContratFondId")).Value);
ImageButton lnkSupprimerContratFonds = (ImageButton)lv.Items[e.ItemIndex].FindControl("lnkSupprimerContratFonds");
string errMsg = String.Empty;
errMsg = ContratFondBLL.DeleteSingleContratFond(contratFondId, ((PageProjet)Page).ProjetId);
if (errMsg.Length == 0)
{
ContratsFondsTransBLL.DeleteAllContratFondTransByContratId(contratFondId, ((PageProjet)Page).ProjetId);
}
else
{
ScriptManager.RegisterClientScriptBlock(this, typeof(Page), "ClientScript", "alert('" + Resources.GPWebResource.errContratFondDelete.ToString() + "')", true);
}
bindContrats();
}
catch(Exception ex)
{
throw (ex);
}
}
<LayoutTemplate>
<div class="wideContainer">
<asp:Literal ID="ltlOrphanWarning" runat="server" Text="OrphanWarning"></asp:Literal>
<asp:PlaceHolder runat="server" ID="itemPlaceHolder" />
<div class="contentDiv">
<asp:LinkButton CssClass="showbtn" ID="btnAjoutContrat" runat="server" Text="AjouterContratAddContract" OnClick="btnAjouterContrat_Click" Visible="false" />
</div>
</div>
</LayoutTemplate>
<ItemTemplate>
<div class="wideContainer">
<div class="contentDiv">
<asp:HiddenField ID="hdnContratId" runat="server" Value='("ContratId") ' />
<div class="titleCellContrats smallCell"><asp:literal ID="ltlContratNum" runat="server" Text="ContratNum"/></div>
<div class="titleCellContrats largeCell"><asp:literal ID="ltlType" runat="server" Text="Type"/></div>
<div class="titleCellContrats mediumCell"><asp:literal ID="ltlDateDND8" runat="server" Text="DateDND8"/></div>
<div class="titleCellContrats mediumCell"><asp:literal ID="ltlDtOctroi" runat="server" Text="ApprovalDateOctroi"/></div>
<div class="titleCellContrats mediumCell"><asp:literal ID="ltlFundsTot" runat="server" Text="ValContratTotal"/></div>
<div class="modCellTitle"> </div>
</div>
<div class="contentDiv">
<div class="contentCellContrats smallCell"><asp:Literal ID="numeroContrat" runat="server"/></div>
<div class="contentCellContrats largeCell boldText"><asp:Literal ID="typeContrat" runat="server" /></div>
<div class="contentCellContrats mediumCell"><asp:Literal ID="dateDND8" runat="server" /></div>
<div class="contentCellContrats mediumCell">
<asp:Literal ID="dateOctroi" runat="server"/>
<asp:CheckBox ID="chkbxOctroi" runat="server" AutoPostBack="false" Enabled="false" />
</div>
<div class="contentCellContrats mediumCell"><asp:Literal ID="ltlTotal" runat="server"/></div>
<div class="modCellContrats">
<asp:ImageButton ID="btnModifierContrat" runat="server" Tooltip="ModifierModify" ImageUrl="~/WebUI/images/icones/edit_16x16.gif" CommandName="Edit" Visible="false" />
<asp:ImageButton ID="btnDeleteContrat" runat="server" Tooltip="Supprimer" ImageUrl="~/WebUI/images/icones/delete_16x16.gif" CommandName="Delete" OnClientClick="SuppContratDeleteContract" Visible="false"/>
</div>
</div>
<div class="contentDiv">
<asp:Literal ID="ltlCommentaires" runat="server"/>
</div>
<div class="contentDiv">
<div class="titleCellContrats Fonds">
<div class="alLeft"><asp:literal ID="ltlfunds" runat="server" Text="ValContrat"/></div>
<div class="alRight smText"><asp:LinkButton ID="lnkAjouterContratFond" runat="server" Text="AjoutEF" OnClick="lnkAjouterContratFond_Click" Visible="false"/></div>
</div>
<asp:ListView
ID="lvContratFonds" runat="server"
InsertItemPosition="None"
OnItemDataBound="lvContratFonds_OnItemDataBound"
ItemPlaceholderID="afficherFonds"
OnItemEditing="lvContratFonds_OnItemEditing"
OnItemUpdating="lvContratFonds_OnItemUpdating"
OnItemCanceling="lvContratFonds_OnItemCanceling"
OnItemDeleting="lvContratFonds_OnItemDeleting"
OnItemInserting="lvContratFonds_OnItemInserting"
OnItemCreated="lvContratFonds_OnItemCreated" >
<LayoutTemplate>
<asp:PlaceHolder runat="server" ID="afficherFonds" />
</LayoutTemplate>
<ItemTemplate>
<div class="contentDiv">
<div class="contFondsRows">
<div class="contentCellContrats ContFonds"><asp:Literal ID="lblAnneeFiscaleEF" runat="server" /></div>
<div class="contentCellContrats ContFonds"><asp:Literal ID="lblFondsContrat" runat="server" /></div>
<div class="contentCellContrats ContFonds">
<strong><asp:Literal ID="ltlDeltaTitle" runat="server" Text="Delta" />:</strong>
<asp:Literal ID="ltlContratFondDelta" runat="server" />
</div>
<div class="modCellCntrFonds">
<asp:ImageButton class="smText" ID="btnModifierContratFonds" runat="server" Tooltip="ModifierModify" ImageUrl="~/WebUI/images/icones/edit_16x16.gif" Height="10" Width="10" CommandName="Edit" Visible="false" />
<asp:ImageButton
class="smText"
ID="lnkSupprimerContratFonds"
runat="server"
Tooltip="Supprimer"
ImageUrl="~/WebUI/images/icones/delete_16x16.gif"
Height="10"
Width="10"
CommandName="Delete"
OnClientClick="SuppFondsDeleteFunds"
Visible="false"/>
<asp:HiddenField ID="hdnContratFondId" runat="server" Value='("ContratFondId") ' />
<asp:HiddenField ID="hdnContratId" runat="server" Value='("ContratId") ' />
<asp:HiddenField ID="hdnAnneeFiscaleId" runat="server" Value='("AnneeFiscaleId") ' />
<asp:HiddenField ID="hdnEF" runat="server" Value='("efID") ' />
</div>
</div>
</div>
</ItemTemplate>
<EditItemTemplate>
<div class="contentDiv">
<asp:HiddenField ID="hdnEditTemplate" runat="server" Value='True' />
<div class="contFondsRows">
<div class="contentCellContrats ContFonds"><asp:DropDownList ID="ddlEF_AF_Prog" runat="server" DataTextField="DisplayField" DataValueField="EF_ID" OnSelectedIndexChanged="ddlEF_Changed" AutoPostBack="true" AppendDataBoundItems="false"></asp:DropDownList></div>
<div class="contentCellContrats ContFonds"><asp:TextBox ID="txtFondsContrat" runat="server"></asp:TextBox> $</div>
<div class="contentCellContrats ContFonds">
<strong><asp:Literal ID="ltlDeltaTitle" runat="server" Text="Delta" />:</strong>
<asp:Literal ID="ltlContratFondDelta" runat="server" />
</div>
<div class="modCellCntrFonds">
<asp:ImageButton
class="smText"
ID="btnEnregistrerContratFonds"
runat="server"
Tooltip="EnregistrerRegister"
ImageUrl="~/WebUI/images/icones/save_16x16.gif"
Height="12"
Width="12"
CommandName="Update" />
<asp:ImageButton class="smText" ID="btnAnnulerContratFonds" runat="server" Tooltip="Cancel" ImageUrl="~/WebUI/images/icones/undo1_16x16.gif" Height="12" Width="12" CommandName="Cancel" CausesValidation="false"/>
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ErrorMessage="FondMontantObligAmntReqd" Display="Dynamic" ControlToValidate="txtFondsContrat" />
<asp:CompareValidator id="CheckFormat1" runat="server" ControlToValidate="txtFondsContrat" Operator="DataTypeCheck" Type="Currency" Display="Dynamic" ErrorMessage="InvalidCurrency" />
<asp:HiddenField ID="hdnContratFondId" runat="server" Value='("ContratFondId") ' />
<asp:HiddenField ID="hdnContratId" runat="server" Value='("ContratId") ' />
<asp:HiddenField ID="hdnAnneeFiscaleId" runat="server" Value='("AnneeFiscaleId") ' />
<asp:HiddenField ID="hdnEF" runat="server" Value='("efID") ' />
</div>
</div>
</div>
<div id="transPanel" class="contentDiv" runat="server">
<asp:UpdatePanel ID="updPnlTransactions" runat="server">
<ContentTemplate>
<uc2:FMASTransControl ID="uc2FMASTransControl" runat="server" ContratMode="true" />
</ContentTemplate>
</asp:UpdatePanel>
</div>
</EditItemTemplate>
<InsertItemTemplate>
<div class="contentDiv">
<div class="contFondsRows">
<div class="contentCellContrats ContFonds"><asp:DropDownList ID="ddlEF_AF_Prog" runat="server" DataTextField="DisplayField" DataValueField="EF_ID" AutoPostBack="true" AppendDataBoundItems="false"></asp:DropDownList></div>
<div class="contentCellContrats ContFonds"><asp:TextBox ID="txtFondsContrat" runat="server"></asp:TextBox> $</div>
<div class="contentCellContrats ContFonds">
<strong><asp:Literal ID="ltlDeltaTitle" runat="server" Text="Delta" />:</strong>
<asp:Literal ID="ltlContratFondDelta" runat="server" Text="AD_InfoNA" />
</div>
<div class="modCellCntrFonds">
<asp:ImageButton ID="btnAjouterCF" runat="server" ClientIDMode="Static" Tooltip="EnregistrerRegister" ImageUrl="~/WebUI/images/icones/save_16x16.gif" Height="12" Width="12" CommandName="Insert" ValidationGroup="insertFondGroup"/>
<asp:ImageButton ID="btnAnnulerCF" runat="server" Tooltip="Cancel" ImageUrl="~/WebUI/images/icones/undo1_16x16.gif" Height="12" Width="12" OnClick="btnAnnulerCF_Click" CausesValidation="false" />
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ErrorMessage="FondMontantObligAmntReqd" Display="Dynamic" ControlToValidate="txtFondsContrat" ValidationGroup="insertFondGroup" />
<asp:CompareValidator id="CheckFormat1" runat="server" ControlToValidate="txtFondsContrat" Operator="DataTypeCheck" Type="Currency" Display="Dynamic" ErrorMessage="InvalidCurrency" />
<asp:HiddenField ID="hdnContratId" runat="server" Value='("ContratId") ' />
</div>
</div>
</div>
</InsertItemTemplate>
</asp:ListView>
</div>
<div class="contentDiv"> </div>
</div>
</ItemTemplate>
<EditItemTemplate>
<div class="wideContainer">
<asp:HiddenField ID="hdnContratId" runat="server" Value='("ContratId") ' />
<asp:HiddenField ID="hdnEditTemplate" runat="server" Value='True' />
<div class="contentDiv">
<div class="titleCellContrats smallCell"><asp:literal ID="ltlContratNum" runat="server" Text="ContratNum"/></div>
<div class="titleCellContrats largeCell"><asp:literal ID="ltlType" runat="server" Text="Type"/></div>
<div class="titleCellContrats mediumCell"><asp:literal ID="ltlDateDND8" runat="server" Text="DateDND8"/></div>
<div class="titleCellContrats mediumCell"><asp:literal ID="ltlDtOctroi" runat="server" Text="ApprovalDateOctroi"/></div>
<div class="titleCellContrats mediumCell"><asp:literal ID="ltlFundsTot" runat="server" Text="Delta"/></div>
<div class="modCellTitle"> </div>
</div>
<div class="contentDiv">
<div class="contentCellContrats smallCell"><asp:TextBox ID="txtContrat" runat="server" MaxLength="8"></asp:TextBox></div>
<div class="contentCellContrats largeCell">
<asp:DropDownList ID="ddlTypeContrat" runat="server" DataTextField="NomChampFieldNm" DataValueField="TypeContratId"></asp:DropDownList>
</div>
<div class="contentCellContrats mediumCell"><uc1:DateControl ID="dateDND8" runat="server" /></div>
<div class="contentCellContrats mediumCell">
<uc1:DateControl ID="dateOctroi" runat="server"/>
<asp:CompareValidator ID="cmpOctroiAfterDND8" runat="server" ControlToCompare="dateDND8$txtDate" ControlToValidate="dateOctroi$txtDate"
ErrorMessage="ErrDateOctroi " Type="Date" Operator="GreaterThanEqual" ToolTip="ErrEndDate ">*</asp:CompareValidator>
<asp:CheckBox ID="chkbxOctroi" runat="server" AutoPostBack="false" onclick="GetTodayDateForOctroi();" />
</div>
<div class="contentCellContrats mediumCell"><asp:Literal ID="ltlTotal" runat="server" Text="" /></div>
<div class="modCellContrats">
<asp:ImageButton ID="btnEnregistrerContrat" runat="server" Tooltip="EnregistrerRegister" ImageUrl="~/WebUI/images/icones/save_16x16.gif" CommandArgument='("ContratId") ' CommandName="Update" />
<asp:ImageButton ID="btnAnnulerContrat" runat="server" Tooltip="Cancel" ImageUrl="~/WebUI/images/icones/undo1_16x16.gif" CommandArgument='("ContratId") ' CommandName="Cancel" />
</div>
</div>
<div class="contentDiv paleBackground <%# Container.DisplayIndex % 2 == 0 ? "" : "altRow" bordered">
<asp:TextBox ID="txtCommentairesContrats" runat="server" Width="100%" MaxLength="250"></asp:TextBox>
<ajx:TextBoxWatermarkExtender ID="tbweCommentairesContrats" runat="server" TargetControlID="txtCommentairesContrats" WatermarkText=" tbweCommentContats" WatermarkCssClass="watermarked" />
</div>
<div class="contentDiv">
<div class="titleCellContrats Fonds">
<div class="alLeft"><asp:literal ID="ltlfunds" runat="server" Text="ValContrat"/></div>
<div class="alRight"><asp:LinkButton class="smText" ID="lnkAjouterContratFond" runat="server" Text="<%$Resources:GPWebResource,AjoutEF" OnClick="lnkAjouterContratFond_Click" Visible="false"/></div>
</div>
<asp:ListView
ID="lvContratFonds"
runat="server"
InsertItemPosition="None"
OnItemDataBound="lvContratFonds_OnItemDataBound"
ItemPlaceholderID="afficherFonds2"
OnItemEditing="lvContratFonds_OnItemEditing"
OnItemUpdating="lvContratFonds_OnItemUpdating"
OnItemCanceling="lvContratFonds_OnItemCanceling"
OnItemDeleting="lvContratFonds_OnItemDeleting"
OnItemInserting="lvContratFonds_OnItemInserting"
OnItemCreated="lvContratFonds_OnItemCreated" >
<LayoutTemplate>
<asp:PlaceHolder runat="server" ID="afficherFonds2" />
</LayoutTemplate>
<ItemTemplate>
<div class="contentDiv">
<div class="contFondsRows">
<div class="contentCellContrats ContFonds"><asp:Literal ID="lblAnneeFiscaleEF" runat="server" /></div>
<div class="contentCellContrats ContFonds"><asp:Literal ID="lblFondsContrat" runat="server" /></div>
<div class="contentCellContrats ContFonds">
<strong><asp:Literal ID="ltlDeltaTitle" runat="server" Text="Delta" />:</strong>
<asp:Literal ID="ltlContratFondDelta" runat="server" />
</div>
<div class="modCellCntrFonds">
<asp:ImageButton class="smText" ID="btnModifierContratFonds" runat="server" Tooltip="ModifierModify" ImageUrl="~/WebUI/images/icones/edit_16x16.gif" Height="10" Width="10" CommandName="Edit" Visible="false" />
<asp:ImageButton class="smText" ID="lnkSupprimerContratFonds" runat="server" Tooltip="Supprimer"
ImageUrl="~/WebUI/images/icones/delete_16x16.gif" Height="10" Width="10" CommandName="Delete"
OnClientClick="SuppFondsDeleteFunds" Visible="false"/>
<asp:HiddenField ID="hdnContratFondId" runat="server" Value='("ContratFondId") ' />
<asp:HiddenField ID="hdnContratId" runat="server" Value='("ContratId") ' />
<asp:HiddenField ID="hdnAnneeFiscaleId" runat="server" Value='("AnneeFiscaleId") ' />
<asp:HiddenField ID="hdnEF" runat="server" Value='("efID") ' />
</div>
</div>
</div>
</ItemTemplate>
</asp:ListView>
</div>
<div class="contentDiv"> </div>
</div>
</EditItemTemplate>
<InsertItemTemplate>
<div class="wideContainer">
<asp:HiddenField ID="hdnContratId" runat="server" Value='("ContratId") ' />
<asp:HiddenField ID="hdnEditTemplate" runat="server" Value='True' />
<div class="contentDiv">
<div class="titleCellContrats smallCell"><asp:literal ID="ltlContratNum" runat="server" Text="ContratNum"/></div>
<div class="titleCellContrats largeCell"><asp:literal ID="ltlType" runat="server" Text="Type"/></div>
<div class="titleCellContrats mediumCell"><asp:literal ID="ltlDateDND8" runat="server" Text="DateDND8"/></div>
<div class="titleCellContrats mediumCell"><asp:literal ID="ltlDtOctroi" runat="server" Text="ApprovalDateOctroi"/></div>
<div class="titleCellContrats mediumCell"><asp:literal ID="ltlFundsTot" runat="server" Text="Delta"/></div>
<div class="modCellTitle"> </div>
</div>
<div class="contentDiv <%# Container.DisplayIndex % 2 == 0 ? "" : "altRow" ">
<div class="contentCellContrats smallCell"><asp:TextBox ID="txtContrat" runat="server" MaxLength="8"></asp:TextBox></div>
<div class="contentCellContrats largeCell">
<asp:DropDownList ID="ddlTypeContrat" runat="server" DataTextField="NomChampFieldNm" DataValueField="TypeContratId"></asp:DropDownList>
</div>
<div class="contentCellContrats mediumCell"><uc1:DateControl ID="dateDND8" runat="server" /></div>
<div class="contentCellContrats mediumCell">
<uc1:DateControl ID="dateOctroi" runat="server" />
<asp:CompareValidator ID="cmpOctroiAfterDND8" runat="server" ControlToCompare="dateDND8$txtDate" ControlToValidate="dateOctroi$txtDate"
ErrorMessage="ErrDateOctroi " Type="Date" Operator="GreaterThanEqual" ToolTip="ErrEndDate ">*</asp:CompareValidator>
</div>
<div class="contentCellContrats mediumCell"><asp:Literal ID="ltlTotal" runat="server" Text="" /></div>
<div class="modCellContrats">
<asp:ImageButton ID="btnAjouterContrat" runat="server" Tooltip="Add " ImageUrl="~/WebUI/images/icones/add_16x16.gif" CommandName="Insert" />
<asp:ImageButton ID="btnAnnulerContrat" runat="server" Tooltip="Cancel" ImageUrl="~/WebUI/images/icones/undo1_16x16.gif" CausesValidation="false" OnClick="btnAnnulerAjouterContrat_Click"/>
</div>
</div>
<div class="contentDiv bordered">
<asp:TextBox ID="txtCommentairesContrats" runat="server" Width="100%" MaxLength="250"></asp:TextBox>
<ajx:TextBoxWatermarkExtender ID="tbweCommentairesContrats" runat="server" TargetControlID="txtCommentairesContrats" WatermarkText="tbweCommentContats" WatermarkCssClass="watermarked" />
</div>
</div>
</InsertItemTemplate>
can you please explain what you mean by "the binding becomes a real mess"? Do you get duplicates?
Also, are you able to post the code for your bindContrats() method?
Edit 1:
ScriptManager.RegisterClientScriptBlock(lvContratFonds, typeof(ListView), "ClientScript", "alert('" + Resources.GPWebResource.errContratFondDelete.ToString() + "')", true);
Edit 2:
if (errMsg.Length == 0)
{
ContratsFondsTransBLL.DeleteAllContratFondTransByContratId(contratFondId, ((PageProjet)Page).ProjetId);
bindContrats(); // re-bind data
}
else
{
e.Cancel = true;
ScriptManager.RegisterClientScriptBlock(this, typeof(Page), "ClientScript", "alert('" + Resources.GPWebResource.errContratFondDelete.ToString() + "')", true);
/* don't re-bind! */
}
Related
I have a question about calling the pop-up registration ..
I want to correct the error for me regarding the pop-up window in my code ..
how can I call it in the VB code correctly to send email ?
And also show me this message " variable' is not declared" in the text boxes ..
What is the problem here?
Code as follows:
VB.net Code :
Protected Sub selectbtn_Click(sender As Object, e As EventArgs)
mpe.Show()
End Sub
Protected Sub SendEmail(sender As Object, e As EventArgs)
Dim EnglishName As String = TryCast(RepeaterCourse.FindControl("lblEnglishName"), Label).Text
Dim ArabicName As String = TryCast(RepeaterCourse.FindControl("lblCourseArabicTitle"), Label).Text
Dim StartCourse As String = TryCast(RepeaterCourse.FindControl("lblStartCours"), Label).Text
Dim EndCourse As String = TryCast(RepeaterCourse.FindControl("lblEndCourse"), Label).Text
Dim Days As String = TryCast(RepeaterCourse.FindControl("lblDays"), Label).Text
Dim CityCountry As String = TryCast(RepeaterCourse.FindControl("lblCountry"), Label).Text
Dim TextName As String = TextName.text
Dim body As String = "Email: " + TextBoxEmail.Text + "<br>" + "Name: " + TextBoxEnglishName.Text + "<br>" + "Country: " + DropDownListCountry.SelectedItem.ToString + "<br>" + "City: " + TextBoxCityName.Text + "<br>" + "Phone: " + TextBoxPhone.Text + "<br>" + "Category: " + DropDownListCategory.SelectedValue + "<br>" + "<br>" + "<br>" + "Message: " + TextComment.Text + "<br>" + hfEnglishName.Value
Dim mail As New System.Net.Mail.MailMessage()
mail.[To].Add("noor#gmail.com")
mail.Bcc.Add("noor#gmail.com")
mail.From = New MailAddress("noor#gmail.com")
mail.Subject = "From Inhouse Training ....By "
mail.Body = body
mail.IsBodyHtml = True
Dim smtp As New SmtpClient("relay-hosting.secureserver.net")
smtp.EnableSsl = False
smtp.UseDefaultCredentials = True
smtp.Send(mail)
LabelMSG.Text = "Sent Successfully"
ClearFields()
End Sub
<div id ="container">
<asp:UpdatePanel runat="server" id="UpdatePanel2" updatemode="Conditional">
<ContentTemplate>
<div class="row">
<div class="container">
<div style="text-align: center;margin-bottom: 10px;font-size: 16px;color: brown;"><asp:Label ID="lblmsg" Text="Registration Successful" runat="server" Visible="false" ></asp:Label></div>
<script type="text/javascript">
function HideLabel() {
var seconds = 5;
setTimeout(function () {
document.getElementById("<%=lblmsg.ClientID%>").style.display = "none";
}, seconds * 1000);
};
</script>
<div class="courses-listing clearfix" style="margin-bottom:30px;">
<asp:Repeater ID="RepeaterCourse" runat="server">
<ItemTemplate>
<div class="col-xs-12 col-sm-6 col-md-4 column threecol">
<div class="course-preview premium-course">
<div class="course-image">
<asp:Label ID="CourseLogo" runat="server" Text='<%# Eval("CourseLogo")%>'></asp:Label>
<%-- <div class="course-price product-price">
<div class="price-text"><span class="amount">$128</span></div>
<div class="corner-wrap">
<div class="corner"></div>
<div class="corner-background"></div>
</div>
</div>--%>
<div class="course-meta">
<header class="course-header">
<h5 class="nomargin"><asp:Label ID="lblEnglishName" runat="server" Text='<%# Eval("EnglishName")%>'></asp:Label></h5>
<br />
<%-- <span style="color: #777; font-size: 0.9em;">innovative tool to streamline the instructional design process.</span> <br />--%>
<h5 class="Arabic-Name"><asp:Label ID="lblCourseArabicTitle" runat="server" data-class="hide" Text='<%# Eval("ArabicName")%>'></asp:Label></h5>
<br />
<p class="author">
<asp:Label ID="lblStartCourse" data-class="hide" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "StartCourse", "{0:dd MMM}")%>'></asp:Label> -
<asp:Label ID="lblEndCourse" runat="server" data-class="hide" Text='<%# DataBinder.Eval(Container.DataItem, "EndCourse" , "{0:dd MMM yyyy}")%>'></asp:Label>
| <asp:Label ID="lblDays" runat="server" data-class="hide" Text='<%# Eval("Days")%>'></asp:Label> Days </p>
<asp:Label ID="lblCountry" data-class="hide" runat="server" Text='<%# Eval("CityCountry")%>'></asp:Label>
</header>
<br />
<div class="course-footer clearfix">
<%-- <asp:LinkButton ID="LinkButton1" runat="server" CausesValidation="false" OnClick="SavePDF" CommandArgument='<%# Eval("BrochoreLink")%>' class="sim-button button14" style="line-height: 20px; color:white;">Download Brochore</asp:LinkButton>--%>
<asp:Button ID="selectbtn" UseSubmitBehavior="false" runat="server" Text="Register" OnClick="selectbtn_Click1" class="sim-button button14" style="line-height: 20px; color:white;"></asp:Button>
<%-- <asp:LinkButton ID="SelectGo" runat="server" Text="Select" ItemStyle-Width="100" CommandName="Select" class="sim-button button14" style="line-height: 20px; color:white;">Register</asp:LinkButton>--%>
<a class="sim-button button14" style="line-height: 20px; color:white;" href='/Brochures/<%# Eval("BrochoreLink")%>' target="_blank" ><span>Download Brochore</span></a>
<%-- <a class="sim-button button14" style="line-height: 20px; color:white;" href="http://store.cglobalc.com/?page_id=1191"><span></span>Register</a>--%>
<a class="sim-button button14" style="line-height: 20px; color:white;" href="InHouseTraining.aspx" target="_blank"><span>Run This Course In-House</span></a>
</div>
</div>
</div>
</div>
<asp:LinkButton Text="" ID="lnkFake" runat="server" />
<cc1:ModalPopupExtender ID="mpe" runat="server" PopupControlID="pnlPopup" TargetControlID="lnkFake"
CancelControlID="btnClose" BackgroundCssClass="modalBackground" >
</cc1:ModalPopupExtender>
<asp:Panel ID="pnlPopup" runat="server" Class="modalPopup" Style="display: none">
<div class="footer" align="right" style="float: right;">
<asp:Button ID="btnClose" runat="server" UseSubmitBehavior="false" Text="x" Style="margin: 2px;
font-size: 22px; color: white; background: none; border: none; border-color: none;
border-radius: 0px;" />
</div>
<div class="login">
<div class="login-header">
<p style="font-size: 30px; font-family: 'Lato', sans-serif; display: block; border-bottom: 1px solid rgba(255, 255, 255, 0.3);
margin: 0 0 0.1em 0; padding-bottom: 20px;">
CONTACT US
</p>
<p style="font-family: 'Lato', sans-serif; font-size: 1.25em; margin: 1em 0 0.4em 0;">
Fill out the form below to complete register!</p>
</div>
<div class="login-form">
<p class="left">
<asp:Label ID="Label1" runat="server" Text="Full Name" CssClass="login-label"></asp:Label>
<asp:TextBox ID="TextBoxName" runat="server" placeholder="Your Name" class="input"></asp:TextBox>
<br />
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" ValidationGroup="Register"
runat="server" ErrorMessage="*" ControlToValidate="TextBoxName" Forecolor="red"></asp:RequiredFieldValidator>
<%--<asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server"
ControlToValidate="TextBoxName" ErrorMessage="Only character"
ValidationExpression="[a-zA-Z]+" Display="dynamic" Forecolor="red" Font-Size ="Small"></asp:RegularExpressionValidator>--%>
</p>
<p style="float: right;">
<asp:Label ID="Label2" runat="server" Text="Email" CssClass="login-label"></asp:Label>
<asp:TextBox ID="TextBoxEmail" runat="server" placeholder="Example#gmail.com" class="input"></asp:TextBox>
<br />
<asp:RegularExpressionValidator ID="valRegEx" ValidationGroup="Register" runat="server"
ControlToValidate="TextBoxEmail" ValidationExpression=".*#.*\..*" ErrorMessage="*Invalid Email address."
Display="dynamic" Forecolor="red" Font-Size ="Small">
</asp:RegularExpressionValidator>
<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ValidationGroup="Register"
ErrorMessage="*" ControlToValidate="TextBoxEmail"></asp:RequiredFieldValidator>
</p>
<p class="left">
<asp:Label ID="Label3" runat="server" Text="Country" CssClass="login-label"></asp:Label>
<asp:TextBox ID="TextBoxCityName" runat="server" placeholder="Your Country" class="input"></asp:TextBox>
<br />
<asp:RequiredFieldValidator ID="RequiredFieldValidator2" ValidationGroup="Register"
runat="server" ErrorMessage="*" ControlToValidate="TextBoxCityName" Forecolor="red"></asp:RequiredFieldValidator>
<%--<asp:RegularExpressionValidator ID="RegularExpressionValidator2" runat="server"
ControlToValidate="TextBoxCityName" ErrorMessage="Only character"
ValidationExpression="[a-zA-Z]+" Display="dynamic" Forecolor="red" Font-Size ="Small"></asp:RegularExpressionValidator>--%>
</p>
<p style="float: right;">
<asp:Label ID="Label4" runat="server" Text="Phone Number" CssClass="login-label"></asp:Label>
<asp:TextBox ID="TextBoxPhone" runat="server" placeholder="Your Phone" class="input"></asp:TextBox>
<br />
<asp:RequiredFieldValidator ID="RequiredFieldValidator4" ValidationGroup="Register"
runat="server" ErrorMessage="*" ControlToValidate="TextBoxPhone" ValidateEmptyText="true"
ValidationExpression="^([0-9\(\)\/\+ \-]*)$" Forecolor="red"></asp:RequiredFieldValidator>
<asp:RegularExpressionValidator ID="RxvMobile" ValidationGroup="Register"
runat="server" ErrorMessage="just number" ControlToValidate="TextBoxPhone" ValidateEmptyText="false"
ValidationExpression="^([0-9\(\)\/\+ \-]*){5,9}$" Forecolor="red" Display="Dynamic" Font-Size ="Small"></asp:RegularExpressionValidator>
</p>
<p class="left">
<asp:Label ID="Label5" runat="server" Text="Comment" CssClass="login-label"></asp:Label>
<asp:TextBox ID="TextBoxComment" runat="server" placeholder="Notes" TextMode="MultiLine"
Rows="4" class="login-textarea"></asp:TextBox><br />
</p>
<p>
<asp:Button ID="Button1" UseSubmitBehavior="false" ValidationGroup="Register" runat="server"
Text="Register" CommandName="Select" class="btn btn-primary" OnClick="SendEmail"
Style="cursor: pointer; border-radius: 5px; box-shadow: none; margin-left: auto;
margin-right: auto; display: block; vertical-align: top;" />
</p>
</div>
</div>
</asp:Panel>
</div>
</ItemTemplate>
</asp:Repeater>
</ContentTemplate>
<Triggers>
</Triggers>
</asp:UpdatePanel>
</div>
Thank you ..
I have multiple tabs on my page and currently I am binding all dropdownlists on every tab at page load.
I want to bind the dropdownlists only when the tab is selected. I also want to clear the gridviews when the tab is changed.
This is my HTML code
<li>
<input type="radio" id="tab1d" name="tabs1" runat="server"/>
<label for="tab1d">Search</label>
<div id="tab-content1d" class="tab-content animated fadeIn" style="background-color:white; padding:10px; ">
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<ContentTemplate>
<asp:Label ID="Label4" runat="server" Text="Select Platform"></asp:Label>
<asp:DropDownList ID="DropDownList3" runat="server" AutoPostBack="true" OnSelectedIndexChanged="DropDownList3_SelectedIndexChanged" CssClass="inputs" Width="150px"></asp:DropDownList>
<asp:Label ID="Label10" runat="server" Text="Select Family Name"></asp:Label>
<asp:DropDownList ID="DropDownList1" runat="server" AutoPostBack="true" CssClass="inputs" Width="150px" OnSelectedIndexChanged="DropDownList1_SelectedIndexChanged"></asp:DropDownList>
<asp:Label ID="Label11" runat="server" Text="Select price Level"></asp:Label>
<asp:DropDownList ID="DropDownList2" runat="server" AutoPostBack="true" CssClass="inputs" Width="150px" ></asp:DropDownList>
<asp:Button ID="Button7" runat="server" Text="Search" CssClass="buttons" OnClick="Button7_Click"/><br /><br />
<div id="gdvLeft">
<asp:GridView ID="gdvFamilyname" runat="server" EnableViewState="True" class="grid" RowStyle-CssClass="rows"></asp:GridView>
</div>
<div id="gdvRight">
<asp:GridView ID="gdvQuantity" runat="server" EnableViewState="True" class="grid" RowStyle-CssClass="rows"></asp:GridView>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</li>
Hi Himani, Try like this -
<input type="radio" value="Click Me" onclick="rdioClick();" />
In Javascript -
function rdioClick() {
var GridView1 = document.getElementById('GridView1');
GridView1.innerHTML = "";
}
Thanks :)
I have looked at all the examples posted and none seem to work for me.
I have the following on an asp .net page
<div style="background-color:#EFEFEF">
<div style="float: left;height: 24px">
<asp:Image ID="PFDExpandColapseImg" runat="server" /> <asp:Label ID="PFDOrgPayDateStatus" runat="server"></asp:Label>
</div>
<div style="float: right;height: 24px">
<asp:ImageButton ID="PFDAuthorizePending" OnClick="PFDAuthorizePending_Click" runat="server" />
<asp:imagebutton ID="PFDReplicate" OnClick="PFDReplicate_Click" runat="server" />
<asp:ImageButton ID="PFDSubmit" OnClick="PFDSubmit_Click" runat="server" />
<asp:ImageButton ID="PFDApprove" OnClick="PFDApprove_Click" runat="server" />
<asp:ImageButton ID="PFDReject" OnClick="PFDReject_Click" runat="server" />
<asp:ImageButton ID="PFDHistory" OnClick="PFDHistory_Click" runat="server" />
<asp:ImageButton ID="PFDDelete" OnClick="PFDDelete_Click" runat="server" />
<asp:ImageButton ID="PFDEdit" OnClick="PFDEdit_Click" runat="server" />
<asp:ImageButton ID="PFDViewExceptions" OnClick="PFDViewExceptions_Click" runat="server" />
<asp:Button ID="PFDEditEmployee" OnClick="PFDEditEmployee_Click" runat="server" />
</div>
<div style="clear: both"></div>
</div>
I am trying to get the the PFDExpandColapseImg and the PFDOrgPayDateStatus to be vertically aligned middle.
If anyone can help it would be very much appreciated.
Some suggested the following to me and it works
<div style="background-color:#EFEFEF">
<div style="float: left;display:flex;align-items:center;height: 24px">
<asp:Image ID="PFDExpandColapseImg" runat="server" /> <asp:Label ID="PFDOrgPayDateStatus" runat="server"></asp:Label>
</div>
<div style="float: right;height: 24px">
<asp:ImageButton ID="PFDAuthorizePending" OnClick="PFDAuthorizePending_Click" runat="server" />
<asp:imagebutton ID="PFDReplicate" OnClick="PFDReplicate_Click" runat="server" />
<asp:ImageButton ID="PFDSubmit" OnClick="PFDSubmit_Click" runat="server" />
<asp:ImageButton ID="PFDApprove" OnClick="PFDApprove_Click" runat="server" />
<asp:ImageButton ID="PFDReject" OnClick="PFDReject_Click" runat="server" />
<asp:ImageButton ID="PFDHistory" OnClick="PFDHistory_Click" runat="server" />
<asp:ImageButton ID="PFDDelete" OnClick="PFDDelete_Click" runat="server" />
<asp:ImageButton ID="PFDEdit" OnClick="PFDEdit_Click" runat="server" />
<asp:ImageButton ID="PFDViewExceptions" OnClick="PFDViewExceptions_Click" runat="server" />
<asp:Button ID="PFDEditEmployee" OnClick="PFDEditEmployee_Click" runat="server" />
</div>
<div style="clear: both"></div>
</div>
The problem is that my ASP controls go out of bounds on the right side of the screen when using the .Fixed class from my CSS.
I tried the 'right: 0; thing but no luck...
See this image.
CSS:
#parent {
display: inline-flex;
}
#narrow {
width: 1000px;
margin-right: 20px;
}
#wide {
width: 100%;
}
.FullWidth {
width:100%;
}
.Fixed {
position: fixed;
}
Short HTML (in asp.net)
<div id="parent">
<div id="narrow">
Contains left gridview
</div>
<div id="parent">
<div id="narrow">
Gridview
</div>
<div id="wide" class="Fixed">
<div>
FormView
</div>
<div>
Contains label and textbox
</div>
</div>
<br />
<div>
Contains right gridview
</div>
<hr />
<div>
Contain textbox and button
</div>
</div>
</div>
Complete HTML
<%# Page Title="" Language="C#" MasterPageFile="~/MasterPages/Security.Master" EnableEventValidation="false" AutoEventWireup="true" CodeBehind="Reports_Read.aspx.cs" Inherits="SecurityV3_Web.ContentPages.Reports.Reports_Read" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server"></asp:ScriptManager>
<asp:UpdatePanel ID="UpdatePanel1" runat="server">
<ContentTemplate>
<div id="parent">
<div id="narrow">
<asp:GridView ID="grdReports" runat="server" DataKeyNames="ReportID" AutoGenerateColumns="false" OnRowDataBound="grdReports_RowDataBound" OnSelectedIndexChanged="GridView1_SelectedIndexChanged">
<Columns>
<asp:BoundField HeaderText="ID" DataField="ReportID" ItemStyle-Width="40px" />
<asp:BoundField HeaderText="Time" DataField="Time" ItemStyle-Width="40px" />
<asp:BoundField HeaderText="Agent" DataField="Name" />
<asp:BoundField HeaderText="Location" DataField="Location" />
<asp:BoundField HeaderText="Header" DataField="Heading" />
</Columns>
</asp:GridView>
</div>
<div id="wide" class="Fixed">
<div>
<asp:FormView ID="FormView1" runat="server" CssClass="FullWidth">
<EmptyDataTemplate>
<p>No data to show. Select a report.</p>
</EmptyDataTemplate>
<ItemTemplate>
<div>
<asp:Label ID="Label1" runat="server" Text="Heading"></asp:Label>
<asp:TextBox ID="txtHeading" runat="server" Text='<%# Eval("Heading") %>'></asp:TextBox>
</div>
<div>
<asp:Label ID="Label2" runat="server" Text="Report"></asp:Label><br />
<asp:TextBox ID="txtReport" runat="server" Text='<%# Eval("Report1") %>' Height="200px" CssClass="FullWidth" TextMode="MultiLine"></asp:TextBox>
</div>
</ItemTemplate>
</asp:FormView>
</div>
<br />
<div>
<asp:GridView ID="grdReplies" runat="server" DataKeyNames="ReportReplyID" AutoGenerateColumns="false">
<Columns>
<asp:BoundField HeaderText="ID" DataField="ReportReplyID" ItemStyle-Width="40px" />
<asp:BoundField HeaderText="Time" DataField="Time" ItemStyle-Width="40px" />
<asp:BoundField HeaderText="Agent" DataField="Name" ItemStyle-Width="100px" />
<asp:BoundField HeaderText="Reply" DataField="Reply1" />
</Columns>
</asp:GridView>
</div>
<hr />
<div>
<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ErrorMessage="This field is required" CssClass="Foutmelding" ControlToValidate="txtReply"></asp:RequiredFieldValidator>
<asp:TextBox ID="txtReply" runat="server" TextMode="MultiLine"></asp:TextBox>
<br />
<asp:Button ID="btnSaveReply" runat="server" Text="Reply" OnClick="btnSaveReply_Click" />
</div>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</asp:Content>
Fiddle
right: 0 is just aligning the fixed element to the right, however it is still full width from the wide ID which makes it take up the whole page. Is { width: auto; right: 0; } an option? That sounds like it would do what you want it to
i've used a DataList (dlparent) control for one of my page. Inside that datalist is another Datalist (dlchild) that is being populated by itemdatabound event of the parent datalist. i've used css with dlchild.
Databinding is ok and the required output shows great with mozilla and IE but not in netscape, safari and google chrome. dlchild is not showing. only item in dlparent appears.
Here's the markup for the dlparent:
<asp:DataList ID="SprintsWorkData" Style="float: left; padding-top: 10px;" runat="server"
OnItemDataBound="SprintsWorkData_ItemDataBound">
<ItemTemplate>
<asp:HiddenField ID="hiddenSprintId" runat="server" Value='<%# Eval("SprintId") %>' />
<div id="SprintNameSection">
<h4>
<%# Eval("SprintName") %></h4>
</div>
<div id="HeaderSection_SelectAll">
<div style="padding-top: 3px; height: 23px; padding-left: 2px;">
<asp:CheckBox ID="isAllCheck" runat="server" onclick="checkAll(this)" />
<b>
<asp:Label ID="sAll" Style="color: Black; text-indent: 1px;" Text="Select All" runat="server"></asp:Label>
</b>
</div>
</div>
<div class="HeaderSection_WorkedHours">
<b><asp:Literal ID="workedHours" runat="server" Text='<%$ Resources:LanguagePack, Worked_Hours %>'></asp:Literal></b></div>
<div class="HeaderSection_BillableHours">
<b><asp:Literal ID="billableHours" runat="server" Text='<%$ Resources:LanguagePack, Billable_Hours %>'></asp:Literal></b></div>
<div class="HeaderSection_Comments">
<b><asp:Literal ID="comments" runat="server" Text='<%$ Resources:LanguagePack, Comments %>'></asp:Literal></b></div>
<asp:DataList ID="HoursWorkData" runat="server">
<ItemTemplate>
<asp:HiddenField ID="hiddenTaskId" runat="server" Value='<%# Eval("BacklogId") %>' />
<div id="ItemSection_Task_Header">
<div style="vertical-align: middle; padding-bottom: 2px; padding-left: 2px; height: 18px;">
<asp:CheckBox ID="checkboxSub" runat="server" onclick="checkAllSub(this)" />
<b style="text-indent: 1px;">
<%# Eval("Title") %></b>
</div>
</div>
<div id="ItemSection_WorkedHours_Header">
<%# Eval("WorkedHours")%> </div>
<div id="ItemSection_BillableHours_Header">
<asp:Label ID="lblBillableHours_Header" Text='<%# Eval("BillableHours")%>' runat="server"></asp:Label> </div>
<div id="ItemSection_Comments_Header">
</div>
<asp:Repeater ID="repResourcesList" runat="server">
<ItemTemplate>
<asp:HiddenField ID="hiddenReportId1" runat="server" Value='<%# Eval("ReportId") %>' />
<div id="ItemSection_Task_Item">
<div style="vertical-align: middle; padding-bottom: 5px; padding-left: 2px; padding-top: 1px;
height: 14px;">
<asp:CheckBox ID="CB" runat="server" onclick="checkItem(this)" />
<b style="text-indent: 1px;">
<%# Eval("EnteredbyName") %></b>
</div>
</div>
<div id="ItemSection_WorkedHours_Item">
<asp:Label ID="lblWorkedHours_Item" Text='<%# Eval("WorkedHours")%>' runat="server"></asp:Label> </div>
<div id="ItemSection_BillableHours_Item">
<asp:RegularExpressionValidator ValidationGroup="ApproveBillable" ID="RegularExpressionValidator1"
runat="server" ErrorMessage="*" ValidationExpression="^(-)?\d+(\.\d\d)?$" ControlToValidate="txtBillableHours"
Style="position: absolute;">*</asp:RegularExpressionValidator>
<asp:TextBox ID="txtBillableHours" Style="text-align: right" runat="server" Font-Size="12px"
Width="50px" Text='<%# Eval("BillableHours") %>'></asp:TextBox>
</div>
<div id="ItemSection_Comments_Item">
<asp:TextBox ID="txtComments" Font-Size="12px" Width="93px" runat="server" Text='<%# Eval("Comment") %>'></asp:TextBox>
</div>
</ItemTemplate>
</asp:Repeater>
</ItemTemplate>
<ItemStyle Height="24px" />
<SeparatorTemplate>
<div id="divSeparator">
</div>
</SeparatorTemplate>
<FooterTemplate>
<div id="Footer1">
TOTAL HOURS
</div>
<div id="Footer_WorkedHours">
<asp:Label ID="lblWorkedHours" runat="server" Text="0.00" Font-Size="12px" ForeColor="White"></asp:Label>
</div>
<div id="Footer_BillableHours">
<asp:Label ID="lblBillableHours_Footer" runat="server" Text="0.00" Font-Size="12px"
ForeColor="White"></asp:Label>
</div>
<div id="Footer_Comments">
</div>
</FooterTemplate>
</asp:DataList>
</ItemTemplate>
<SeparatorTemplate>
</SeparatorTemplate>
</asp:DataList>
What might be the problem?
<asp:DataList ID="SprintsWorkData" Style="float: left; padding-top: 1px;" runat="server"
OnItemDataBound="SprintsWorkData_ItemDataBound">
<ItemTemplate>
<asp:HiddenField ID="hiddenSprintId" runat="server" Value='<%# Eval("SprintId") %>' />
<div id="SprintNameSection">
<h4>
<%# Eval("SprintName") %></h4>
</div>
<div id="HeaderSection_SelectAll">
<div style="padding-top: 3px; height: 23px; padding-left: 2px;">
<asp:CheckBox ID="isAllCheck" runat="server" onclick="checkAll(this)" />
<b>
<asp:Label ID="sAll" Style="color: Black; text-indent: 1px;" Text="Select All" runat="server"></asp:Label>
</b>
</div>
</div>
<div class="HeaderSection_WorkedHours">
<b>
<asp:Literal ID="workedHours" runat="server" Text='<%$ Resources:LanguagePack, Worked_Hours %>'></asp:Literal></b></div>
<div class="HeaderSection_BillableHours">
<b>
<asp:Literal ID="billableHours" runat="server" Text='<%$ Resources:LanguagePack, Billable_Hours %>'></asp:Literal></b></div>
<div class="HeaderSection_Comments">
<b>
<asp:Literal ID="comments" runat="server" Text='<%$ Resources:LanguagePack, Comments %>'></asp:Literal></b></div>
<asp:DataList ID="HoursWorkData" runat="server" Style="float: left;">
<ItemTemplate>
<asp:HiddenField ID="hiddenTaskId" runat="server" Value='<%# Eval("BacklogId") %>' />
<div id="ItemSection_Task_Header">
<div style="vertical-align: middle; padding-bottom: 2px; padding-left: 2px; height: 18px;">
<asp:CheckBox ID="checkboxSub" runat="server" onclick="checkAllSub(this)" />
<b style="text-indent: 1px;">
<%# Eval("Title") %></b>
</div>
</div>
<div id="ItemSection_WorkedHours_Header">
<%# Eval("WorkedHours")%> </div>
<div id="ItemSection_BillableHours_Header">
<asp:Label ID="lblBillableHours_Header" Text='<%# Eval("BillableHours")%>' runat="server"></asp:Label> </div>
<div id="ItemSection_Comments_Header">
</div>
<asp:Repeater ID="repResourcesList" runat="server">
<ItemTemplate>
<asp:HiddenField ID="hiddenReportId1" runat="server" Value='<%# Eval("ReportId") %>' />
<div id="ItemSection_Task_Item">
<div style="vertical-align: middle; padding-bottom: 5px; padding-left: 2px; padding-top: 1px;
height: 14px;">
<asp:CheckBox ID="CB" runat="server" onclick="checkItem(this)" />
<b style="text-indent: 1px;">
<%# Eval("EnteredbyName") %></b>
</div>
</div>
<div id="ItemSection_WorkedHours_Item">
<asp:Label ID="lblWorkedHours_Item" Text='<%# Eval("WorkedHours")%>' runat="server"></asp:Label> </div>
<div id="ItemSection_BillableHours_Item">
<asp:RegularExpressionValidator ValidationGroup="ApproveBillable" ID="RegularExpressionValidator1"
runat="server" ErrorMessage="*" ValidationExpression="^(-)?\d+(\.\d\d)?$" ControlToValidate="txtBillableHours"
Style="position: absolute;">*</asp:RegularExpressionValidator>
<asp:TextBox ID="txtBillableHours" Style="text-align: right" runat="server" Font-Size="12px"
Width="50px" Text='<%# Eval("BillableHours") %>'></asp:TextBox>
</div>
<div id="ItemSection_Comments_Item">
<asp:TextBox ID="txtComments" Font-Size="12px" Width="93px" runat="server" Text='<%# Eval("Comment") %>'></asp:TextBox>
</div>
</ItemTemplate>
</asp:Repeater>
</ItemTemplate>
<ItemStyle Height="24px" />
<SeparatorTemplate>
<div id="divSeparator">
</div>
</SeparatorTemplate>
<FooterTemplate>
<div id="Footer1">
<asp:Literal ID="totalHours" runat="server" Text='<%$ Resources:LanguagePack,TOTAL_HOURS %>'></asp:Literal>
</div>
<div id="Footer_WorkedHours">
<asp:Label ID="lblWorkedHours" runat="server" Text="0.00" Font-Size="12px" ForeColor="White"></asp:Label>
</div>
<div id="Footer_BillableHours">
<asp:Label ID="lblBillableHours_Footer" runat="server" Text="0.00" Font-Size="12px"
ForeColor="White"></asp:Label>
</div>
<div id="Footer_Comments">
</div>
</FooterTemplate>
</asp:DataList>
</ItemTemplate>
<SeparatorTemplate>
</SeparatorTemplate>
</asp:DataList>
I've just forgot to add float:left to the inner datalist or dlchild. the parent datalist has float:left