asp.net - Dynamically populate AJAX hovermenu when hovering -


Loading When I instead of populating the whole gridview of the Hoverman data, I hover over a hover menu when I hover over it The page should be able to populate In other words, I need to populate them "on the fly".

I have inserted the contents of the popup in the web user control with the example text. I then have this user control when popping from hover over a GridView line

Here is the .aspx page:

  & lt; ASP:. Panel id = "popuppanel" runat = "server" cssClass = "modal" style = "display: none;" & Gt; & Lt; G3: order detailspeopleup id = "order pop up" runat = "server" & gt; & Lt; / G3: Order DetailsPop & gt; & Lt; / ASP: Cell & gt; & Lt; ajaxToolkit: HoverMenuExtender id = "HoverPopupExtender" runat = "server" TargetControlID = "PopupPanel" PopupControlID = "PopupPanel" PopupPosition = "top" PopDelay = "0" / & gt;   

The contents of the user control "OderDetailsPopup":

  & lt;% @ Control Language = "VB" AutoEventWireup = "false" CodeFile = "OrderDetailsPopup .ascx.vb "Inherits =" UserControls_OrderDetailsPopup "%> & Lt; ASP: panel id = "popuppanel" runat = "server" & gt; & Lt; Div class = "modal-header" & gt; & Lt; H3 & gt; Order Details & lt; / H3 & gt; & Lt; / Div & gt; & Lt; Div class = "modal-body" & gt; & Lt; ASP: label ID = "label" run = "server" & gt; LABELBABEL & lt; / Asp: label & gt; & Lt; / Div & gt; & Lt; / ASP: Cell & gt;   

and the old code behind the .aspx page (I was just populating the page's obligation, instead of the user control above, Gridview was on the 'gvOrderDetails' page. for both removed to simplify this example):

  protect sub GridView1_RowCreated (as this object, manages) GridView1.RowCreated e GridViewRowEventArgs e.Row.RowType = DataControlRowType.DataRow then dim hoverMenu as HoverMenuExtender = e.Row.FindControl ( "HoverPopupExtender") e.Row.ID = e.Row.RowIndex.ToString () hoverMenu .TargetControlID = e.Row.ID End Sub GridView1_RowDataBound (the End Sub preserved as object, e GridViewRowEventArgs as) handles GridView1.RowDataBound If e.Row.RowType = DataControlRowType.DataRow the grid as the grid view grid = E.Row.Cells (5) .FindControl ("gvOrderDetails") Description Grid. Data Source = new G3.Entity.TaskDetails () .GetDetailsByOrder (CType (e.Row.DataItem, DataRowView) ( "travel order ID") Details grid. Detaband () End End End End End    To expand, my hoverman was working well, but it was taking a very long time to load a page of 300 rows, and each line had a popup hover menu which it would do with its data So these goals are here:  
  • Popup code in user control
  • Hooverman's on-the-fly popup.

    Actually, we decided to call only DB when user control is loaded. It extremely better page-load time and much more problem solved.

      public function RenderMe (in Stringbilder = new Stringbilder (as integer Ordraidi) string Dim Stringbillder) if ID & gt; 0 F And ViewModel = new VM () ViewModel.ID = id ViewModel.Fill () OrderDetails.DataSource = ViewModel.T DataBind () Dim stringWriter StringWriter = new StringWriter (StringBuilder) as dim as writer HtmlTextWriter = new HtmlTextWriter ( StringWriter) Present (Author) End if Return StringBiltter Toastring () termination function    

Comments

Popular posts from this blog

c - Mpirun hangs when mpi send and recieve is put in a loop -

python - Apply coupon to a customer's subscription based on non-stripe related actions on the site -

java - Unable to get JDBC connection in Spring application to MySQL -