Search Results

Search found 1705 results on 69 pages for 'runat'.

Page 11/69 | < Previous Page | 7 8 9 10 11 12 13 14 15 16 17 18  | Next Page >

  • Applying a Dojo Toolkit (Dijit) theme to ASP.NET pages.

    - by mcoolbeth
    In the code below, I am trying to apply a Dijit theme to the controls in my .aspx page. However, the controls persist in their normal, unthemed appearance. Anybody know why? Master Page: <%@ Master Language="C#" AutoEventWireup="true" CodeBehind="Main.master.cs" Inherits="WebJournalEntryClient.Main" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" > <head runat="server"> <title>My Web Application</title> <link rel="stylesheet" href="dojoroot/dijit/themes/tundra/tundra.css" /> <script type="text/javascript" src="dojoroot/dojo/dojo.js"/> <script type="text/javascript"> dojo.require("dijit.form.Button"); dojo.require("dijit.form.TextBox"); dojo.require("dijit.form.ComboBox"); </script> </head> <body class = "tundra"> <form id="form1" runat="server"> <div> <div> This is potentially space for a header bar. </div> <table> <tr> <td> Maybe <br /> a <br /> Side <br /> bar. </td> <td> <asp:ContentPlaceHolder ID="CenterPlaceHolder" runat="server"/> </td> </tr> </table> <div> This is potentially space for a footer bar. </div> </div> </form> </body> </html> Content Page: <%@ Page Title="" Language="C#" MasterPageFile="~/Main.Master" AutoEventWireup="true" CodeBehind="LogIn.aspx.cs" Inherits="WebJournalEntryClient.LogIn" %> <asp:Content ID="Content" ContentPlaceHolderID="CenterPlaceHolder" runat="server"> <div> User ID: <asp:TextBox ID = "UserName" dojoType="dijit.form.TextBox" runat="server" /><br /> Password: <asp:TextBox ID = "PassWord" dojoType="dijit.form.TextBox" runat="server" /><br /> <asp:Button ID="LogInButton" Text="Log In" dojoType="dijit.form.Button" runat="server" /> </div> </asp:Content>

    Read the article

  • Two-way data binding of controls in a user control inside a FormView

    - by Sandor Drieënhuizen
    I'm trying to perform two-way data binding on the controls in my user control, which is hosted inside a FormView template. FormView: <asp:ObjectDataSource runat="server" ID="ObjectDataSource" TypeName="WebApplication1.Data" SelectMethod="GetItem" UpdateMethod="UpdateItem"> </asp:ObjectDataSource> <asp:FormView runat="server" ID="FormView"> <ItemTemplate> <uc:WebUserControl1 runat="server"></uc:WebUserControl1> </ItemTemplate> <EditItemTemplate> <uc:WebUserControl1 runat="server"></uc:WebUserControl1> </EditItemTemplate> </asp:FormView> User control: <%@ Control Language="C#" ... %> <asp:TextBox runat="server" ID="TitleTextBox" Text='<%# Bind("Title") %>'> </asp:TextBox> The binding works fine when the FormView is in View mode but when I switch to Edit mode, upon calling UpdateItem on the FormView, the bindings are lost. I know this because the FormView tries to call an update method on the ObjectDataSource that does not have an argument called 'Title'. I tried to solve this by implementing IBindableTemplate to load the controls that are inside my user control, directly into the templates (just like I had entered them declaratively like in the code above). However, when calling UpdateItem in edit mode, the container that gets passed into the ExtractValues method of the template, does not contain the TextBox anymore. It did in view mode! I have found some questions on SO that relate to this problem but they are rather dated and don't provide straight forward answers. How do you think I could solve this problem? It seems to be such a simple requirement but apparently it's more like opening a can of worms...

    Read the article

  • tigra calendar and asp.net help, or using javascript in asp.net

    - by MyHeadHurts
    <input type="text" name="testinput" /> <script language="JavaScript"> new tcal ({ // form name 'formname': 'testform', // input name 'controlname': 'testinput' }); </script> <form id="form2" runat="server"> <div style="height: 897px"> <asp:ScriptManager ID="ScriptManager1" runat="server"> </asp:ScriptManager> <br /> <asp:Button ID="Button1" runat="server" Text="Update" Width="122px" /> <br /> <br /> TESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTEST<br /> TESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTEST<br /> TESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTEST<br /> TESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTEST<br /> TESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTESTTEST<br /> aaaaaaaaaaaaaaaaaaaaaaaa<br /> <br /> <br /> <asp:UpdatePanel ID="UpdatePanel1" runat="server"> <ContentTemplate> <asp:GridView ID="GridView2" runat="server" CellPadding="4" ForeColor="#333333" GridLines="None" Height="147px" Width="694px"> <RowStyle BackColor="#E3EAEB" /> <FooterStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" /> <PagerStyle BackColor="#666666" ForeColor="White" HorizontalAlign="Center" /> <SelectedRowStyle BackColor="#C5BBAF" Font-Bold="True" ForeColor="#333333" /> <HeaderStyle BackColor="#1C5E55" Font-Bold="True" ForeColor="White" /> <EditRowStyle BackColor="#7C6F57" /> <AlternatingRowStyle BackColor="White" /> </asp:GridView> <br /> <br /> <asp:TextBox ID="TextBox1" runat="server" Height="33px" Width="179px">fsafasfa</asp:TextBox> </ContentTemplate> </asp:UpdatePanel> </div> </form> I am using tigra calender in an asp.net page, but the datepicker will not show up. The img folder path is the same and i even placed it in my apdata. I took the code straight from the sample page, and I have even used tigra calender before, but not with asp.net any ideas. Is there another calender tool i should be using?

    Read the article

  • Why won't my image display??

    - by Josh
    Hello All- Do y'all see anything wrong with my code below? I want my image to appear immediately after page opens but it only opens after the report is run. Please let me know. Thanks. <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SelectionReport.aspx.cs" Inherits="Geocortex.Essentials.WebFramework.SelectionReportPage" Culture="auto" UICulture="auto" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" > <head id="Head1" runat="server"> <title><asp:Literal meta:resourcekey="Title1" runat="server" /></title> </head> <body> <form id="form1" runat="server"> <p> <asp:Image ID="Image1" runat="server" ImageAlign="Left" ImageUrl="~/Images/Loading.gif" style="z-index: 1; left: 254px; top: 15px; position: absolute" /> </p> <gcx:SelectionReportViewer ID="SelectionReportViewer" runat="server" /> </form> </body>

    Read the article

  • CSS Menus having cross browser problems

    - by George
    I am trying to solve a problem with a CSS menu where the menu does not display properly in IE 6 I see that the HTML has some conditional code to make it work with different browsers but I do not understand it well enough. Can someone suggest a fix so the selected tab in order displayed without the grey breaK? Thanks! #pad { height: 140px; } .dropline { position: relative; padding-bottom: 0px; list-style-type: none; margin: 0px 0px 0px 5px; padding-left: 0px; width: 860px; padding-right: 0px; background: url(../images/menus/ulback.gif) repeat-x; height: 40px; top: 0px; list-style-image: none; padding-top: 0px; left: 5px; } .dropline TABLE { margin: -3px -10px; width: 25px; border-collapse: collapse; height: 17px; } .dropline LI { margin-bottom: 0px; float: left; } .dropline LI A { padding-bottom: 0px; line-height: 40px; padding-left: 0px; padding-right: 19px; display: block; font-family: tahoma, sans-serif; float: left; height: 40px; color: #fff; font-size: 12px; text-decoration: none; padding-top: 0px; } .dropline A { text-align: right; padding-bottom: 0px; line-height: 40px; padding-left: 0px; padding-right: 19px; font-family: tahoma, sans-serif; float: right; height: 40px; color: #fff; font-size: 12px; text-decoration: none; padding-top: 0px; } .dropline A:hover { color: yellow; } .welcomeuser { text-align: right; padding-bottom: 0px; line-height: 40px; padding-left: 20px; padding-right: 0px; font-family: tahoma, sans-serif; float: right; height: 40px; color: #fff; clear: inherit; font-size: 12px; text-decoration: none; padding-top: 0px; } .dropline LI A B { padding-bottom: 0px; padding-left: 20px; padding-right: 0px; display: block; float: left; height: 40px; cursor: pointer; padding-top: 0px; } .dropline UL { z-index: 10; border-bottom: #fff 1px solid; position: absolute; padding-bottom: 0px; list-style-type: none; margin: 0px; padding-left: 0px; width: 860px; padding-right: 0px; background: #f8f8f8; height: 25px; border-top: #ff9933 3px solid; top: 40px; list-style-image: none; padding-top: 0px; left: -9999px; } .dropline UL LI { line-height: 25px; height: 25px; } .dropline UL.right LI { float: right; } .dropline UL LI A { padding-bottom: 0px; line-height: 25px; padding-left: 10px; padding-right: 10px; height: 25px; color: #000; font-size: 11px; font-weight: bold; border-right: #e60 1px solid; padding-top: 0px; } .dropline UL LI A:hover { line-height: 25px; background: none transparent scroll repeat 0% 0%; height: 25px; color: #c60; } .dropline UL.right LI A { border-left: #e60 1px solid; border-right: 0px; } .dropline UL LI A.last { border-bottom: 0px; border-left: 0px; border-top: 0px; border-right: 0px; } .dropline :hover UL { left: 0px; } .dropline LI.current UL { z-index: 1; left: 0px; } .dropline LI.current A { line-height: 36px; background: url(../images/menus/tab_a.gif) no-repeat right top; height: 44px; } .dropline LI.current A B { line-height: 36px; background: url(../images/menus/tab_b.gif) no-repeat left top; } .dropline LI.current UL LI A { padding-bottom: 0px; line-height: 25px; padding-left: 10px; padding-right: 10px; background: none transparent scroll repeat 0% 0%; height: 25px; color: #000; padding-top: 0px; } .dropline LI.current UL LI.current_sub A { color: #c60; } .dropline LI.current UL LI A:hover { color: #c60; } <div id="top_nav"> <asp:ContentPlaceHolder ID="phTopNav" runat="server"> <!-- MENU --> <ul id="dropline" class="dropline" runat="server" style="left: -6px; top: -2px; width:1000px;" clientidmode="Static"> <li runat="server" id="Home"> <a runat="server" id="lnkHome" href="../Default.aspx" title="Go to the Home page"><b>Home</b> <!--[if gte IE 7]><!--></a> <!--<![endif]--> <!--[if lte IE 6]> <table> <tr> <td> <![endif]--><!--[if lte IE 6]> </td> </tr> </table> </a><![endif]--> </li> <li runat="server" id="ApplyNow"> <a runat="server" id="lnkEditOrder" href="../OrderChinaVisa.aspx" title="Use our Price Calculator and simultaneously begin the China Visa application process!"><b>Apply Now!</b> <!--[if gte IE 7]><!--></a> <!--<![endif]--> <!--[if lte IE 6]> <table> <tr> <td> <![endif]--><!--[if lte IE 6]> </td> </tr> </table> </a><![endif]--> </li> <li runat="server" id="CheckStatus"> <a id="lnkCheckStatus" runat="server" href="../Check_Status.aspx" title="Check on the status of a placed order"><b>Check Status</b><!--[if gte IE 7]><!--></a><!--<![endif]--> <!--[if lte IE 6]> <table> <tr> <td> <![endif]--><!--[if lte IE 6]> </td> </tr> </table> </a><![endif]--></li> <li runat="server" id="Affiliate"> <a id="lnkAffiliate" runat="server" href="../Secure/VisaActivity.aspx" title=""><b>Affiliate</b><!--[if gte IE 7]><!--></a><!--<![endif]--> <!--[if lte IE 6]> <table> <tr> <td> <![endif]--><!--[if lte IE 6]> </td> </tr> </table> </a><![endif]--></li> </ul> </asp:ContentPlaceHolder> </div>

    Read the article

  • ASP.NET with jQueryUI: text box value is getting as null in Button click event

    - by Shyju
    I have an ASP.NET page where I have a button When a user clicks on the button,I will check whether the user has logged in or not.If not logged in I will show a modal popup to login (using jQueryUI). I have placed one textbox(txtPassword) and one button(btnLogin) control in the Div which will be shown by the jQueryDialog.But in btnLogin's Click event, I am not able to read the Text value entered in the textbox txtPassword The below is my code <form id="form1" runat="server"> <div> <br /> <asp:TextBox ID="txtModelId" runat="server" Text=""></asp:TextBox><br /> <asp:Button ID="btnGo" runat="server" Text="Go" OnClick="btnGo_Click" /> <br /> <asp:Label ID="lblUserMsg" runat="server" Text="Label"></asp:Label></div> <div id="divContentHolder"> <div class="demo"> <div id="dialog" title="Login with your TradeIn Account"> <p id="validateTips">Enter your EmailId & password</p> <fieldset> <label for="email">Email</label> <asp:TextBox ID="txtEmail" CssClass="text ui-widget-content ui-corner-all" runat="server" ></asp:TextBox> <label for="password"> <asp:TextBox ID="TextBox1" runat="server" Text="sample"></asp:TextBox>Password</label> <asp:TextBox ID="txtPassword" CssClass="text ui-widget-content ui-corner-all" runat="server" ></asp:TextBox> <asp:Button ID="btnLogin" runat="server" Text="Login" OnClick="btnLogin_Click" UseSubmitBehavior="false"/> </fieldset> </div><!--dialog--> </div><!--demo--> </div><!--divContentHolder--> </form> Server side Code protected void btnGo_Click(object sender, EventArgs e) { CheckUserLoggedIn(); } private void CheckUserLoggedIn() { if (Session["username"] != null) { Response.Write("Logged in user"); ClientScript.RegisterHiddenField("isAuthenticated", "true"); } else { ClientScript.RegisterHiddenField("isAuthenticated", "false"); } } protected void btnLogin_Click(object sender, EventArgs e) { string txtSample= TextBox1.Text; // this is showing the value 'sample' string txtPass= txtPassword.Text; // this is showing null if (txtPass == "shyju") { Session["username"] = txtPassword.Text; Response.Redirect("TestingModal.aspx"); } } My java script code to render the dialog $(function() { var name = $("#name"), email = $("#email"), password = $("#password"), allFields = $([]).add(name).add(email).add(password), tips = $("#validateTips"); function updateTips(t) { tips.text(t).effect("highlight",{},1500); } function checkLength(o,n,min,max) { if ( o.val().length > max || o.val().length < min ) { o.addClass('ui-state-error'); updateTips("Length of " + n + " must be between "+min+" and "+max+"."); return false; } else { return true; } } function checkRegexp(o,regexp,n) { if ( !( regexp.test( o.val() ) ) ) { o.addClass('ui-state-error'); updateTips(n); return false; } else { return true; } } $("#dialog").dialog({ bgiframe: true, autoOpen: false, height: 300, modal: true, buttons: { 'Create an account': function() { var bValid = true; allFields.removeClass('ui-state-error'); bValid=true; if (bValid) { /*$('#users tbody').append('<tr>' + '<td>' + name.val() + '</td>' + '<td>' + email.val() + '</td>' + '<td>' + password.val() + '</td>' + '</tr>'); */ alert("Check User Credentials") $(this).dialog('close'); } }, Cancel: function() { $(this).dialog('close'); } }, close: function() { allFields.val('').removeClass('ui-state-error'); } }); $('#create-user').click(function() { $('#dialog').dialog('open'); }) .hover( function(){ $(this).addClass("ui-state-hover"); }, function(){ $(this).removeClass("ui-state-hover"); } ).mousedown(function(){ $(this).addClass("ui-state-active"); }) .mouseup(function(){ $(this).removeClass("ui-state-active"); }); var isAuthenticated = $("#isAuthenticated").val(); if (isAuthenticated && isAuthenticated == "false") { // Display the modal dialog. $("#dialog").dialog("open"); } }); I had hard coded the text properties value of TextBox1 as 'sample' in the HTML part of my ASPX file .In button click event i am getting it.But the other textbox,txtPassword 's Text property is giving me null value Please guide me to go ahead Thanks in advance

    Read the article

  • Javascript code inside updatepanel usercontrol.

    - by Ed Woodcock
    Ok: I've got an updatepanel on an aspx page that contains a single Placeholder. Inside this placeholder I'm appending one of a selection of usercontrols depending on certain external conditions (this is a configuration page). In each of these usercontrols there is a bindUcEvents() javascript function that binds the various jQuery and javascript events to buttons and validators inside the usercontrol. The issue I'm having is that the usercontrol's javascript is not being recognised. Normally, javascript inside an updatepanel is executed when the updatepanel posts back, however none of this code can be found by the page (I've tried running the function manually via firebug's console, but it tells me it cannot find the function). Does anyone have any suggestions? Cheers, Ed. EDIT: cut down (but functional) example: Markup: <script src="/js/jquery-1.3.2.min.js"></script> <form id="form1" runat="server"> <div> <asp:ScriptManager ID="Script" runat="server" /> <asp:Button ID="Postback" runat="server" Text="Populate" OnClick="PopulatePlaceholder" /> <asp:UpdatePanel ID="UpdateMe" runat="server"> <Triggers> <asp:AsyncPostBackTrigger ControlID="Postback" EventName="Click" /> </Triggers> <ContentTemplate> <asp:Literal ID="Code" runat="server" /> <asp:PlaceHolder ID="PlaceMe" runat="server" /> </ContentTemplate> </asp:UpdatePanel> </div> </form> C#: protected void PopulatePlaceholder(object sender, EventArgs e) { Button button = new Button(); button.ID = "Push"; button.Text = "push"; button.OnClientClick = "javascript:return false;"; Code.Text = "<script type=\"text/javascript\"> function bindEvents() { $('#" + button.ClientID + "').click(function() { alert('hello'); }); } bindEvents(); </script>"; PlaceMe.Controls.Add(button); }

    Read the article

  • Menu Control in Master Page fails to use CSS styles

    - by Shaun
    I'm working on a web application that uses ASP.NET 3.5 and C#. Structurally, I have a master page with a menu control on it. The control serves as my navigation, and it gets its items from a SiteMapDataSource control and a corresponding Web.sitemap file. The problem is that some styles do not render properly when you specify the CssClass property. More specifically, the selected and hover styles don't respond to css styles. Consider the code below: <%@ Master Language="C#" AutoEventWireup="true" CodeFile="Site.master.cs" Inherits="Site" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.or/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title>A webpage</title> </head> <body> <form id="form1" runat="server"> <div id="page"> <asp:Menu ID="navMenu" Orientation="Horizontal" StaticMenuStyle-CssClass="staticMenu" StaticMenuItemStyle-CssClass="staticMenuItem" StaticSelectedStyle-CssClass="staticSelectedItem" StaticHoverStyle-CssClass="staticHoverItem" runat="server"> </asp:Menu> <asp:SiteMapDataSource ID="srcSiteMap" runat="server" ShowStartingNode="false" /> <br /> <asp:ContentPlaceHolder id="ContentPlaceHolder1" runat="server"> </asp:ContentPlaceHolder> </div> </form> </body> </html> Suppose I had a corresponding .css file with the following: .staticMenuItem { background-color:Red; } .staticSelectedItem { background-color:Green; } .staticHoverItem { background-color:Blue; } What will happen is that my item backgrounds will properly be red, but my selected item will not be green and the item I'm hovering my mouse over will not be blue. This seems true regardless of whether or not I include the style in the head of the master page or in an external file in default theme as specified in the web.config file. If I specify the styles in the asp.net xml like so: <asp:Menu ID="navMenu" Orientation="Horizontal" runat="server"> <StaticSelectedStyle BackColor="Green" Font-Underline="True" Font-Bold="True" /> <StaticHoverStyle BackColor="Gray" /> </asp:Menu> It appears to work properly in Firefox, but the style is never embedded in the html in Internet Explorer. Odd. Does anybody have any insight into what is causing this problem and how to neatly work around it? I'm aware I might be able to programmically determine the current page and select the corresponding menu item manually so it receives the proper style class, but before I resort to hacking C# and Javascript together to fix this functionality, I'm open to ideas.

    Read the article

  • MOSS 2007 team site page title

    - by nav
    Hi, I'm trying to display the page title (html title) on the default.aspx page of a custom site template. The template is based on a MOSS team site template. All that displays is the URL of the page as the page title. Can I change the code in the default.aspx and/or the sites master page to define the title myself? Details of the deafult.aspx and default.master page as below: Thanks. Default.aspx: <asp:Content ContentPlaceHolderId="PlaceHolderPageTitle" runat="server"> <SharePoint:EncodedLiteral runat="server" text="<%$Resources:wss,multipages_homelink_text%>" EncodeMethod="HtmlEncode"/> - <SharePoint:ProjectProperty Property="Title" runat="server"/> </asp:Content> default.master <Title ID=onetidTitle><asp:ContentPlaceHolder id=PlaceHolderPageTitle runat="server"/></Title>

    Read the article

  • How do I get ASP.NET login status controls to display a Log In option?

    - by Greg McNulty
    I have the following log in status controls on the top of my master page. It displays the logged in as, manager log in, and Log out options. However, when a user is not logged in, there is nothing displayed there. When the user is NOT logged in, is there a way to display a "Login" text link that takes you to the log in page and then "disappears" once the user is logged in? Any help is appreciated. Thanks! <asp:LoginName ID="LoginName1" runat="server" FormatString="Logged in as {0}" ForeColor="Aqua" /> <asp:LoginView ID="LoginView1" runat="server"> <RoleGroups> <asp:RoleGroup Roles="Managers"> <ContentTemplate> <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="~/Management/management.aspx">Manage Site</asp:HyperLink> or <asp:LoginStatus id="LoginStatus1" runat="server" /> </ContentTemplate> </asp:RoleGroup> </RoleGroups> <LoggedInTemplate> (<asp:LoginStatus id="LoginStatus1" runat="server" />) </LoggedInTemplate> </asp:LoginView> ASP.NET 3.5 VWD 2008 C#

    Read the article

  • ASP.Net ListBox selections not working in Panel?

    - by larryq
    Hi everyone, I'm having trouble processing a listbox after selecting some items from it. In my markup, the listbox is contained within an asp:panel and is populated during page load in the codebehind. That part works fine. It's when I select various items and submit that I have trouble. My handler loops through the listbox items but doesn't see any as being selected. I'm not sure why. Here's the markup: <asp:Panel ID="panEdit" runat="server" Height="180px" Width="400px" CssClass="ModalWindow"> <table width="100%"> <asp:label runat = "server">Choose your items</asp:label> <tr> <td> <asp:ListBox ID="lstFundList" runat="server" SelectionMode="Multiple" OnLoad="lstFundList_LoadData"> </asp:ListBox> </td> </tr> </table> <asp:Button ID="btnUpdate" runat="server" Text="Update" OnClick="btnUpdate_OnClick"/> <asp:Button ID="btnCancel" runat="server" Text="Cancel" OnClientClick="$find('ModalPopupExtender1').hide(); return false;" /> </asp:Panel> In my btnUpdate_OnClick handler I can't see any listbox items that are marked as selected. I assume something strange is going on with respect to postback and the panel?

    Read the article

  • Multiple Concurrent Postbacks when using UpdatePanels

    - by d4nt
    Here's an example app that I built to demonstrate my problem. A single aspx page with the following on it: <form id="form1" runat="server"> <asp:ScriptManager runat="server" /> <asp:Button runat="server" ID="btnGo" Text="Go" OnClick="btnGo_Click" /> <asp:UpdatePanel runat="server"> <ContentTemplate> <asp:TextBox runat="server" ID="txtVal1" /> </ContentTemplate> </asp:UpdatePanel> </form> Then, in code behind, we have the following: protected void btnGo_Click(object sender, EventArgs e) { Thread.Sleep(5000); Debug.WriteLine(string.Format("{0}: {1}", DateTime.Now.ToString("HH:MM:ss.fffffff"), txtVal1.Text)); txtVal1.Text = ""; } If you run this and click on the "Go" button multiple times you will see multiple debug statements on the "Output" window showing that multiple requests have been processed. This appears to contradict the documented behaviour of update panels (i.e. If you make a request while one is processing, the first requests gets terminated and the current one is processed). Anyway, the point is I want to fix it. The obvious option would be to use Javascript to disable the button after the first press, but that strikes me as hard to maintain, we potentially have the same issue on a lot of screens it could be easily broken if someone renames a button. Do you have any suggestions? Perhaps there is something I could do in BeginRequest in Global.asax to detect a duplicate request? Is there some setting or feature on the UpdatePanel to stop it doing this, or maybe something in the AjaxControlToolkit that will prevent it?

    Read the article

  • ASP.NET AsyncPostBackTrigger disables button's OnClick function???

    - by hahuang65
    I saw another post like this: http://stackoverflow.com/questions/1795621/asyncpostbacktrigger-disables-buttons But I don't really know what to make of it. The accepted answer was poorly typed. Basically, I have a button with an OnClick function. I also have a UpdatePanel, with is AsyncPostBackTrigger set to that same button. It seems that if I do this, my Button no longer does ANYTHING. I guess it's because I have a Page_Load() event... Can anyone explain why this is? And how should I set up my webpage if I can't use the Page_Load() function? Oh and if I put my Button in a UpdatePanel, it also won't do anything, probably because of the same reason. This is a section of my code: <asp:FileUpload id="FileUploadControl" runat="server" /> <asp:Button runat="server" id="UploadButton" text="Upload" OnClick="uploadClicked" /> <br /><br /> <asp:Label runat="server" id="StatusLabel" text="Upload status: " /> <br /> <asp:UpdatePanel ID="UpdatePanel2" runat="server" updatemode="Conditional" > <ContentTemplate> <asp:DropDownList ID="songList" runat="server" /> </ContentTemplate> <Triggers> <asp:AsyncPostBackTrigger ControlID="RefreshButton" /> </Triggers> </asp:UpdatePanel> Thanks in advance.

    Read the article

  • System.MissingMemberException was unhandled by user code

    - by AmRoSH
    I'm using this code: Dim VehiclesTable1 = dsVehicleList.Tables(0) Dim VT1 = (From d In VehiclesTable1.AsEnumerable _ Select VehicleTypeName = d.Item("VehicleTypeName") _ , VTypeID = d.Item("VTypeID") _ , ImageURL = d.Item("ImageURL") _ , DailyRate = d.Item("DailyRate") _ , RateID = d.Item("RateID")).Distinct its linq to dataset and I Take Data on THis Rotator: <telerik:RadRotator ID="RadRotatorVehicleType" runat="server" Width="620px" Height="145" ItemWidth="155" ItemHeight="145" ScrollDirection="Left" FrameDuration="1" RotatorType="Buttons"> <ItemTemplate> <div style="text-align: center; cursor: pointer; width: 150px"> <asp:Image ID="ImageVehicleType" runat="server" Width="150" ImageUrl='<%# Container.DataItem("ImageURL") %>' /> <asp:Label ID="lblVehicleType" runat="server" Text='<%# Container.DataItem("VehicleTypeName") %>' Font-Bold="true"></asp:Label> <br /> <asp:Label ID="lblDailyRate" runat="server" Text='<%# Container.DataItem("DailyRate") %>' Visible="False"></asp:Label> <input id="HiddenVehicleTypeID" type="hidden" value='<%# Container.DataItem("VTypeID") %>' name="HiddenVehicleTypeID" runat="server" /> <input id="HiddenRateID" type="hidden" value='<%# Container.DataItem("RateID") %>' name="HiddenRateID" runat="server" /> </div> </ItemTemplate> <ControlButtons LeftButtonID="img_left" RightButtonID="img_right" /> </telerik:RadRotator> and I got this Exception: No default member found for type 'VB$AnonymousType_0(Of Object,Object,Object,Object,Object)'. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.MissingMemberException: No default member found for type 'VB$AnonymousType_0(Of Object,Object,Object,Object,Object)'. I don't know whats up ? Any help please. Thanks for who tried to solve this but I got solution: using '<%# DataBinder.Eval(Container.DataItem,"ImageURL") %>' instead of '<%# Container.DataItem("RateID") %>' Thanks,

    Read the article

  • Ajax Control Toolkit CalendarExtender not closing when form body clicked.

    - by TampaRich
    I am trying to simply have the calendar close when a user clicks anywhere on the page. I have downloaded the most recent version of the toolkit and I can not get this functionality to work. I am not sure if I am missing a property but the functionality works as expected on the asp.net sample toolkit page. Here is the code: <asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server"> </asp:ToolkitScriptManager> <asp:TextBox ID="txtTest" runat="server" /><img runat="server" alt="Calendar" id="imgCalFrom" align="absmiddle" border="0" height="16" src="/global/images/glo_btn_cal.gif" width="21"/> <asp:CalendarExtender ID="CalendarExtender1" runat="server" TargetControlID="txtTest" PopupButtonID="imgCalFrom"> </asp:CalendarExtender>

    Read the article

  • onCommand on button not firing inside gridView??

    - by sah302
    This is really driving me crazy. I've got a button inside a gridview to remove that item from the gridview (its datasource is a list). I've got the list being saved to session anytime a change is being made to it, and on page_load check if that session variable is empty, if not, then set that list to bind to the gridview. Code Behind: Public accomplishmentTypeDao As New AccomplishmentTypeDao() Public accomplishmentDao As New AccomplishmentDao() Public userDao As New UserDao() Public facultyDictionary As New Dictionary(Of Guid, String) Public facultyList As New List(Of User) Public associatedFaculty As New List(Of User) Public facultyId As New Guid Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load 'If Not Session("associatedFaculty") Is Nothing Then' ' Dim associatedFacultyArray As User() = DirectCast(Session("associatedFaculty"), User())' ' associatedFaculty = associatedFacultyArray.ToList()' 'End If' Page.Title = "Add a New Faculty Accomplishment" ddlAccomplishmentType.DataSource = accomplishmentTypeDao.getEntireTable() ddlAccomplishmentType.DataTextField = "Name" ddlAccomplishmentType.DataValueField = "Id" ddlAccomplishmentType.DataBind() facultyList = userDao.getListOfUsersByUserGroupName("Faculty") For Each faculty As User In facultyList facultyDictionary.Add(faculty.Id, faculty.LastName & ", " & faculty.FirstName) Next If Not Page.IsPostBack Then ddlFacultyList.DataSource = facultyDictionary ddlFacultyList.DataTextField = "Value" ddlFacultyList.DataValueField = "Key" ddlFacultyList.DataBind() End If gvAssociatedUsers.DataSource = associatedFaculty gvAssociatedUsers.DataBind() End Sub Protected Sub deleteUser(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.CommandEventArgs) facultyId = New Guid(e.CommandArgument.ToString()) associatedFaculty.Remove(associatedFaculty.Find(Function(user) user.Id = facultyId)) Session("associatedFaculty") = associatedFaculty.ToArray() gvAssociatedUsers.DataBind() upAssociatedFaculty.Update() End Sub Protected Sub btnAddUser_Click(ByVal sender As Object, ByVal e As EventArgs) Handles btnAddUser.Click facultyId = New Guid(ddlFacultyList.SelectedValue) associatedFaculty.Add(facultyList.Find(Function(user) user.Id = facultyId)) Session.Add("associatedFaculty", associatedFaculty.ToArray()) gvAssociatedUsers.DataBind() upAssociatedFaculty.Update() End Sub Protected Sub Delete(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.CommandEventArgs) End Sub End Class Markup: <asp:UpdatePanel ID="upAssociatedFaculty" runat="server" UpdateMode="Conditional"> <ContentTemplate> <p><b>Created By:</b> <asp:Label ID="lblCreatedBy" runat="server"></asp:Label></p> <p><b>Accomplishment Type: </b><asp:DropDownList ID="ddlAccomplishmentType" runat="server"></asp:DropDownList></p> <p><b>Accomplishment Applies To: </b><asp:DropDownList ID="ddlFacultyList" runat="server"></asp:DropDownList> &nbsp;<asp:Button ID="btnAddUser" runat="server" Text="Add Faculty" OnClientClick="incrementCounter();" /></p> <p> <asp:GridView ID="gvAssociatedUsers" runat="server" AutoGenerateColumns="false" GridLines="None" ShowHeader="false"> <Columns> <asp:BoundField DataField="Id" HeaderText="Id" Visible="False" /> <asp:TemplateField ShowHeader="False"> <ItemTemplate> <span style="margin-left: 15px;"> <p><%#Eval("LastName")%>, <%#Eval("FirstName")%> <asp:Button ID="btnUnassignUser" runat="server" CausesValidation="false" CommandArgument='<%# Eval("Id") %>' CommandName="Delete" OnCommand="deleteUser" Text='Remove' /></p> </span> </ItemTemplate> </asp:TemplateField> </Columns> <EmptyDataTemplate> <em>There are currently no faculty associated with this accomplishment.</em> </EmptyDataTemplate> </asp:GridView> </p> </ContentTemplate> </asp:UpdatePanel> Now here is the crazy part I am simply boggled by, if I uncomment the If Not Session... block of page_load, then deleteUser will never fire when btnUnassignUser is clicked. If I keep it commented out...it fires no problem, but then of course my list can never have more than one item since I am not loading the saved list from session into the gridview but just a fresh one. But the button click is being registered, because page_load is being stepped through again when I am viewing in debug mode, just deleteUser never fires. Why is this happening?? And how can I fix it??

    Read the article

  • Client-side validation breaks in IE because of PropertyProxyValidator and ScriptManager cooperation.

    - by Eugene
    The specific of the project is in using Enterpise Library for Server side validation and jQuery for client-side validation. So I have the next simple form for example: <asp:Content ID="_mainContent" ContentPlaceHolderID="MainContent" runat="server"> <script src="../../../Scripts/jquery-1.3.2.js" type="text/javascript"></script> <script src="../../../Scripts/jquery.validate.js" type="text/javascript"></script> <script type="text/javascript"> $(document).ready(function() { $("#aspnetForm").validate({ rules: { "<%= _txtProjectName.UniqueID %>": { required: true } } }); }); </script> <asp:TextBox ID="_txtProjectName" runat="server" CssClass="textBoxWithValidator_long" /> <entlib:PropertyProxyValidator id="_validatorProjectName" runat="server" ControlToValidate="_txtProjectName" PropertyName="ProjectName" SourceTypeName="LabManagement.Project.Project" /> <asp:Button CssClass="cell_InlineElement" ID="_btnSave" runat="server" Text="Save" onclick="_btnSave_Click" Width="50px" /> <asp:ScriptManager ID="ScriptManager1" runat="server" EnablePageMethods="true"> </asp:ScriptManager> </asp:Content> The problem is in the next: client-side validation worked correctly before I needed to implement some AJAX.NET feature. So I have to add to the page ScriptManager (the last two lines in the code). But after that the next situation appeared: In InternetExplorer((7) - only in IE !!! - in Firefox everything works correctly) after clicking save button, if left the textbox ProjectName empty the client-side jquery validation appears but (!) the page submits to the server anyway. Some notes: If delete PropertyProxyValidator from the page - the client-side validation works correctly in IE but I need it for specific of the project. It seems that the problem is in the function WebForm_OnSubmit() that is inserted to the form after PropertyProxyValidator adding. ( ... <form name="aspnetForm" method="post" action="Project.aspx?TransType=NewProject" onsubmit="javascript:return WebForm_OnSubmit();" ...>) Could anyone help, please.

    Read the article

  • Button in Update Panel doing full postback?

    - by sah302
    No this isn't a copy of this question: http://stackoverflow.com/questions/654423/button-in-update-panel-is-doing-a-full-postback I've got a drop down inside an update panel, and I am trying to get it to allow the person using the page to add users to a list that is bound to a gridview. The list is a global variable, and on page_load I set that to the gridview's datasource and databind it. However, anytime I click the 'add a user' button, or the button to remove the user from the list. It appears like it is doing a full post back even though all these elements are inside the update Panel. Code Behind: Public accomplishmentTypeDao As New AccomplishmentTypeDao() Public accomplishmentDao As New AccomplishmentDao() Public userDao As New UserDao() Public facultyDictionary As New Dictionary(Of Guid, String) Public facultyList As New List(Of User) Public associatedFaculty As New List(Of User) Public facultyId As New Guid Protected Sub Page_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load Page.Title = "Add a New Faculty Accomplishment" ddlAccomplishmentType.DataSource = accomplishmentTypeDao.getEntireTable() ddlAccomplishmentType.DataTextField = "Name" ddlAccomplishmentType.DataValueField = "Id" ddlAccomplishmentType.DataBind() facultyList = userDao.getListOfUsersByUserGroupName("Faculty") For Each faculty As User In facultyList facultyDictionary.Add(faculty.Id, faculty.LastName & ", " & faculty.FirstName) Next If Not Page.IsPostBack Then ddlFacultyList.DataSource = facultyDictionary ddlFacultyList.DataTextField = "Value" ddlFacultyList.DataValueField = "Key" ddlFacultyList.DataBind() End If gvAssociatedUsers.DataSource = associatedFaculty gvAssociatedUsers.DataBind() End Sub Protected Sub deleteUser(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.CommandEventArgs) facultyId = New Guid(e.CommandArgument.ToString()) associatedFaculty.Remove(associatedFaculty.Find(Function(user) user.Id = facultyId)) gvAssociatedUsers.DataBind() upAssociatedFaculty.Update() End Sub Protected Sub btnAddUser_Click(ByVal sender As Object, ByVal e As EventArgs) Handles btnAddUser.Click facultyId = New Guid(ddlFacultyList.SelectedValue) associatedFaculty.Add(facultyList.Find(Function(user) user.Id = facultyId)) gvAssociatedUsers.DataBind() upAssociatedFaculty.Update() End Sub Markup: <asp:ScriptManager ID="ScriptManager1" runat="server"> </asp:ScriptManager> <asp:UpdatePanel ID="upAssociatedFaculty" runat="server" UpdateMode="Conditional"> <ContentTemplate> <p><b>Created By:</b> <asp:Label ID="lblCreatedBy" runat="server"></asp:Label></p> <p><b>Accomplishment Type: </b><asp:DropDownList ID="ddlAccomplishmentType" runat="server"></asp:DropDownList></p> <p><b>Accomplishment Applies To: </b><asp:DropDownList ID="ddlFacultyList" runat="server"></asp:DropDownList> &nbsp;<asp:Button ID="btnAddUser" runat="server" Text="Add Faculty" /></p> <p> <asp:GridView ID="gvAssociatedUsers" runat="server" AutoGenerateColumns="false" GridLines="None" ShowHeader="false"> <Columns> <asp:BoundField DataField="Id" HeaderText="Id" Visible="False" /> <asp:TemplateField ShowHeader="False"> <ItemTemplate> <span style="margin-left: 15px;"> <p><%#Eval("LastName")%>, <%#Eval("FirstName")%> <asp:Button ID="btnUnassignUser" runat="server" CausesValidation="false" CommandArgument='<%# Eval("Id") %>' CommandName="Delete" OnCommand="deleteUser" Text='Remove' /></p> </span> </ItemTemplate> </asp:TemplateField> </Columns> <EmptyDataTemplate> <em>There are currently no faculty associated with this accomplishment.</em> </EmptyDataTemplate> </asp:GridView> </p> </ContentTemplate> </asp:UpdatePanel> Now I thought the point of an update panel was to be able to update things inside of it without doing a full post_back and reloading the page. So if that's the case, why is it calling page_load everytime I click the buttons? I ran this code and debug and I see that even before any of the code associated with button press fires, page_load runs again. I tried putting the gvAssociatedUser.Datasource = associatedFaculty and the line below inside the Page.IsPostBack check, that prevented the page from working. I tried every combination of settings of the update panel for ChildrenAsTriggers and UpdateMode, and none of them worked. I know this is something simple, but all the combinations I've tried won't get it to work. How can I make this thing work?

    Read the article

  • CSS Collapsing/Hiding divs with no data in <span>

    - by Chance
    I am trying to display an address which includes the following information: Title, division, address1, address2, town/state/zip, and country (5 seperate lines worth of data). The problem is sometimes the company may only have the title, address1, and town/state/zip yet other times it may be all but address2. This is determined upon a db record request server side. Therefore how can I make my output look proper when some of my labels will be blank? I would like div's that contain an empty span to be essentially collapsed/removed. My only idea of how was to use jquery and a selector to find all divs with blank spans (since thats all an asp.net label really is) and then remove those divs however this seems like such bad form. Is there any way to do this with css? Possible Code would be something like: $('span:empty:only-child').parent('div').remove(); Picture Examples (Ignore spacing/indentation issues which I will fix) Missing Division, Address2, and Country All Possible Fields The Html <asp:Label runat="server" ID="lblBillingAddressHeader" CssClass="lblBillingAddressHeader" Text="Billing Address:" /> <div style="position:relative; top:150px; left: 113px;"> <div class="test"> <asp:Label runat="server" ID="lblBillingDivision" CssClass="lblBillingShippingDivisionFont" /> </div> <div class="test"> <asp:Label runat="server" ID="lblBillingAddress" CssClass="lblBillingShippingFont" /> </div> <div class="test"> <asp:Label runat="server" ID="lblBillingAddress2" CssClass="lblBillingShippingFont" /> </div> <div class="test"> <asp:Label runat="server" ID="lblBillingAddress3" CssClass="lblBillingShippingFont" /> </div> <div class="test"> <asp:Label runat="server" ID="lblBillingAddress4" CssClass="lblBillingShippingFont" /> </div> </div> The CSS .test { position: relative; top: 0px; left: 0px; height: 12px; width: 300px; } .lblBillingShippingDivisionFont { font-size: small; font-weight: bold; } .lblBillingShippingFont { font-size: 10.6px; }

    Read the article

  • Add special characters to Asp.net RegularExpressionValidator for E-Mail

    - by Hasan Gürsoy
    I have a e-mail address validator but I need to add special characters as valid for example ü, ç... Because users in Turkey (or anywhere else) can have a web site url like: hasangürsoy.com My code is below: <asp:TextBox ID="tEMail" runat="server" /> <asp:RequiredFieldValidator ID="rfvEMail" runat="server" ControlToValidate="tEMail" ErrorMessage="* required" /> <asp:RegularExpressionValidator ID="revEMail" runat="server" ControlToValidate="tEMail" ErrorMessage="* invalid" ValidationExpression="\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*" />

    Read the article

  • asp.net ajax collapsible panel in ie8 problem

    - by stuart
    Anyone try this simple bit of code in an ie8 browswer and try refreshing the page, in ie8 you will get an error around getelementbyid on refresh. When i run it it complains of not being able to find control with id of 'ctl00_main_dd' <cc1:CollapsiblePanelExtender ID="CollapsiblePanelExtender2" runat="server" ImageControlID="Image2" CollapsedImage="~/App_Themes/IMStandard/icons/uparrow.png" ExpandedImage="~/App_Themes/IMStandard/icons/downarrow.png" CollapseControlID="dd" ExpandControlID="dd" TargetControlID="pnlQuickKeywordSearch" SuppressPostBack="true"> </cc1:CollapsiblePanelExtender> <asp:Panel ID="dd" runat="server"> <h3 class="loginHeader"> <asp:Image ID="Image2" runat="server" /> &nbsp;&nbsp;Quick Keyword search&nbsp;<asp:Image ID="HelpIconImage" runat="server" Width="16px" Height="16px" ImageUrl="~/App_Themes/IMStandard/icons/help.png" /></h3> </asp:Panel> <asp:Panel ID="pnlQuickKeywordSearch" Style="float: left; border: double 3px #C9DF86;" runat="server" > <div style="clear: both; padding: 5px;"> </div></asp:Panel> Anybody know why this is happening? is it a bug in ie8 or am i missing something? By the way, i am using masterpages, but i dont think that has anything to do with it. Thanks

    Read the article

  • Change the source of an image by clicking a thumbnail (without jQuery preferably using UpdatePanel)

    - by Batu
    For example, i have this ImageViewer.ascx UserControl: <div class="ImageTumbnails"> <asp:ListView ID="ImageList" runat="server" ItemPlaceholderID="ItemContainer"> <LayoutTemplate> <asp:PlaceHolder ID="ItemContainer" runat="server" /> </LayoutTemplate> <ItemTemplate> <asp:HyperLink runat="server" NavigateUrl='<%# Link.ToProductImage(Eval("ImageFile").ToString())%>'> <asp:Image runat="server" ImageUrl='<%# Link.ToThumbnail(Eval("ImageFile").ToString()) %>' /> </asp:HyperLink> </ItemTemplate> </asp:ListView> </div> <div class="ImageBig"> <asp:Image ID="ProductImageBig" runat="server" ImageUrl="" /> </div> When the thumbnail is clicked it will change the source of ProductImageBig with its hyperlink target. How can i achieve this using UpdatePanel ? ( Or will i be able to )

    Read the article

  • divert asp.net child controls

    - by Eric
    Hi Folks, I am trying to create an asp.net custom control that acts as a hosting container for any other controls, similar to the existing ‘Panel’ control. Basically, I need to build a web control that groups a bunch of other controls. It will consist of a header and a body pane, similar to a normal window in desktop application. The header will contain some simple text and some JavaScript driven code that shows/hides the body pane. The body pane simply hosts any number of other controls. +------------------------------------------------------+ | User Details Show/Hide | +------------------------------------------------------+ | Name: [Eric ] | | Address: [Some where] | | Date of Birth: [01/01/1980] | | | | (any other fields goes on) | | | | | +------------------------------------------------------+ Ideally I want to create a control that packs the whole thing together, so at design time I could use the following markup. <myCtl:SuperContainer runat=”server” Title=”User Details”> <asp:label id=”lblName” runat=”server” text=”Name:”/> <asp:textbox id=”txtName” runat=”server”/> <asp:label id=”lblDOB” runat=”server” text=”Date of Birth:”/> <asp:textbox id=”txtDOB” runat=”server”/> (…other controls definition…) </myCtl:SuperContainer> I plan to include two panels in my control, one for the header and another one for the body, but as you can see, the key issue is to find a way to ‘divert’ the child controls that are defined in the markup to the body panel, instead of the default parent container. I feel it can be some how simply override (manipulate) the control property, but don’t know how to properly do so. Can any one give some idea about how to implement this ‘SuperContainer’ control? Many thank, Eric

    Read the article

  • event capturing or bubbling

    - by ChampionChris
    I have a link button in a repeater control. the li element is drag and droppable using jquery. when the page loads the the link button works perfectly, the jquery that is attached and the server side code both execute. when I perform a drag and drop then click on the link button it doesn't not fire. when i click it a second time it does fire. If i perform 2 or drag and drops in a row the link button doesn't fire a as many drag and drops as i before it will fire. for example if if perform 3 drag and drops then it will take about 3 click before the events are fired. <asp:Repeater ID="rTracks" runat="server" OnItemDataBound="rTracks_ItemDataBound" EnableViewState="true"> <ItemTemplate> <li onclick="testclick();" class='admin-song ui-selectee <asp:Literal id="ltStatusClass" runat="server" />' mediaid="<%# Eval("MediaId") %>" artistid="<%# Eval("tbMedia.tbArtists.id") %>"><span class="handle"><strong> <%--<%# int.Parse(DataBinder.Eval(Container, "ItemIndex", "")) + 1%>--%><%# Eval("SortNumber")%></strong><%--0:03--%></span> <span class="play"><span class="btn-play">&nbsp;</span></span> <span class="track" title="<%# Eval("tbMedia.Title") %>"> <%# Eval("tbMedia.Title") %></span> <span class="artist"> <%# Eval("tbMedia.tbArtists.Name") %></span> <span class="time" length="<%# Eval("tbMedia.Length") %>"> <asp:Literal ID="ltRuntime" runat="server" /></span> <span class="notes"><span class="btn-notes"> <asp:Literal ID="ltNotesCount" runat="server" /></span></span> <span class="status"> <asp:Literal ID="ltStatus" runat="server" /></span> <span class="date"> <%# Eval("DateAdded") %></span> <span class="remove"><asp:LinkButton ID="lbStatusClass2" runat="server" CssClass="btn-del" OnClick="UpdateStatus" ValidationGroup='<%#Bind("MediaId") %>'> <%--<span class='<asp:Literal id="ltStatusClass2" runat="server" Text="btn-del" />'>--%> &nbsp;<%--</span>--%></asp:LinkButton></span></span> </li> </ItemTemplate> </asp:Repeater> I have onclick event on the li element, when the mouse is clicks the link button the li onclick event is fired even when linkbutton event doesnt fire. My question is if the li captures the event y doesnt the event fire on the linkbutton? What would be stopping the event?

    Read the article

  • how to bind repeater control as message threading

    - by Shalin Gajjar
    i have crm application. i have one difficulties that how i bind repeater control as message threading. like first thread as question and second thread as answer of that question. if user asked multiple question then first,second,.. threads as question and.as it is like message chatting... for keeping data from database i use this stored procedure: set ANSI_NULLS ON set QUOTED_IDENTIFIER ON GO ALTER PROCEDURE [dbo].[ViewMessageThreads] (@inquiry_id varchar(50)) AS BEGIN SET NOCOUNT ON; select i.body as master_body, h.body as history_body, q.body as question_body, q.Created_date as question_timestamp, a.body as answer_body, a.Created_date as answer_timestamp, t.Type_name as user_type from tbl_Inquiry_History i left join tbl_Inquiry_master h on h.Inquiry_id=i.Inquiry_id left join tbl_Question q on q.Inquiry_id=i.Inquiry_id left join tbl_Answer a on a.Question_id=q.Inquiry_id left join tbl_User_master u on u.Id=i.User_id left join tbl_Login_master l on l.Id=u.User_id left join tbl_Type t on t.Id = l.type_id where (i.Inquiry_id=@inquiry_id) END and this gives me result as: master_body history_body question_body question_t.. answer_body answer_t.. user_type __________________________________________________________________________________________ question 1 NULL question 1 2005-03-14... NULL NULL User question 1 NULL question 2 2005-03-14... NULL NULL User and i include this design source of repeater: <asp:Repeater ID="Repeater_Inquiry_Messages" runat="server"> <ItemTemplate> <table id="ctl00_ContentPlaceHolder1_dl_ticketmsg" cellspacing="0" border="0" style="width:100%;border-collapse:collapse;"> <tbody><tr> <td style="background-color:#F5F5FF;"> <table cellpadding="0" cellspacing="0" border="0"> <tbody><tr> <td class="header"> <span id="ctl00_ContentPlaceHolder1_dl_ticketmsg_ctl00_lbl_msg_no"><%#Container.ItemIndex+1 %></span></td> <td class="normaltext" valign="bottom"> <span id="ctl00_ContentPlaceHolder1_dl_ticketmsg_ctl00_lbl_tagline">Message By <b><asp:Label ID="lbl_user_t" runat="server" Text='<%#Eval("user_type")%>'/></b> on <asp:Label ID="lbldatetime" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "question_timestamp","{0:ddd, dd MMMM yyyy}")%>'/></span></td> </tr> <tr> <td class="header"> &nbsp;</td> <td class="normaltext" valign="bottom"> <b>Message :</b><br> <span id="ctl00_ContentPlaceHolder1_dl_ticketmsg_ctl00_Label1"><asp:Label ID="lbl_inquiry_desc" runat="server" Text='<%#Eval("question_body")%>'/></span></td> </tr> </tbody></table> </td> </tr> </tbody></table> </ItemTemplate> <SeparatorTemplate> <table> <tr> <td style="height:3px"></td> </tr> </table> </SeparatorTemplate> <ItemTemplate> <table id="ctl00_ContentPlaceHolder1_dl_ticketmsg1" cellspacing="0" border="0" style="width:100%;border-collapse:collapse;"> <tbody><tr> <td style="background-color:#F5F5FF;"> <table cellpadding="0" cellspacing="0" border="0"> <tbody><tr> <td class="header"> <span id="ctl00_ContentPlaceHolder1_dl_ticketmsg1_ctl00_lbl_msg_no"><%#Container.ItemIndex+1 %></span></td> <td class="normaltext" valign="bottom"> <span id="ctl00_ContentPlaceHolder1_dl_ticketmsg1_ctl00_lbl_tagline">Message By <b><asp:Label ID="Label1" runat="server" Text='<%#Eval("user_type")%>'/></b> on <asp:Label ID="Label2" runat="server" Text='<%# DataBinder.Eval(Container.DataItem, "answer_timestamp","{0:ddd, dd MMMM yyyy}")%>'/></span></td> </tr> <tr> <td class="header"> &nbsp;</td> <td class="normaltext" valign="bottom"> <b>Message :</b><br> <span id="ctl00_ContentPlaceHolder1_dl_ticketmsg1_ctl00_Label1"><asp:Label ID="Label3" runat="server" Text='<%#Eval("answer_body")%>'/></span></td> </tr> <tr> <td class="header"> &nbsp;</td> <td class="normaltext" valign="bottom"> <b></b> </td> </tr> </tbody></table> </td> </tr> </tbody></table> </ItemTemplate> </asp:Repeater> how ever this gives me only question thread while i commenting up this second message thread. ----------------------------------------Updated--------------------------------------- please help me.. ---------------------------------------Updated---------------------------------------- Server Error in '/OmInvestmentStockMarketing_new' Application. Compilation Error Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately. Compiler Error Message: CS1026: ) expected Source Error: Line 162: <span id="ctl00_ContentPlaceHolder1_dl_ticketmsg_ctl00_lbl_msg_no"><%#Container.ItemIndex+1 %></span></td> Line 163: <td class="normaltext" valign="bottom"> Line 164: <span id="ctl00_ContentPlaceHolder1_dl_ticketmsg_ctl00_lbl_tagline">Message By <b><asp:Label ID="lbl_user_t" runat="server" Text='<%# If(Eval("cargo2").ToString() Is "Admin", "You", Eval("cargo2"))%>'/></b> Line 165: on <asp:Label ID="lbldatetime" runat="server" Text='<%# DataBinder.Eval(Container.DataItem,"cargo1","{0:ddd, dd MMMM yyyy}")%>'/></span></td> Line 166: </tr> Source File: c:\Documents and Settings\Vishal\My Documents\Visual Studio 2005\WebSites\OmInvestmentStockMarketing_new\Admin\OWM_Inquiry.aspx Line: 164 Show Detailed Compiler Output: Show Complete Compilation Source: Version Information: Microsoft .NET Framework Version:2.0.50727.3053; ASP.NET Version:2.0.50727.3053

    Read the article

< Previous Page | 7 8 9 10 11 12 13 14 15 16 17 18  | Next Page >