我在updatepanel中有一个gridview,它允许分页,并且有一个链接按钮,当点击时会显示一个用于编辑记录的modalpopup。这在IE,Firefox和Opera中运行良好,但我没有在Chrome或Safari中获得回发?我在页面上有其他链接按钮在updatepanels内但不在gridviews中工作正常。我已经浏览了网络,但无法找到解决方案。我的部分代码如下,任何人都有任何想法吗?
#
<asp:UpdatePanel ID="upReports" runat="server" UpdateMode="Conditional">
# <ContentTemplate>
# <asp:HiddenField ID="hfMachID" runat="server" />
# <asp:HiddenField ID="hfNewLead" runat="server" Value="no" />
# <div class="fullWidth">
# <div class="heading">
# <h2 style="padding:10px">
# <asp:Label ID="lblResults" runat="server" />
# </h2>
# </div>
#
# <!-- Machine Leads -->
# <asp:GridView ID="gvMachLeads" runat="server" Visible="false" AutoGenerateColumns="false"
# GridLines="None" CssClass="mGrid" AlternatingRowStyle-CssClass="alt" AllowPaging="true"
# OnPageIndexChanging="gvMachLeads_PageIndexChanging" PagerStyle-CssClass="pgr"
# onrowcommand="gvMachLeads_RowCommand" PageSize="15">
# <Columns>
# <asp:TemplateField HeaderText="Created" ItemStyle-HorizontalAlign="Center">
# <ItemTemplate>
# <asp:Label ID="lblDate" runat="server" Text='<%# Eval("DateC") %>'
# CssClass="repGridText" ToolTip='<%# "Origin: " + Eval("LeadOrigin") %>' />
# </ItemTemplate>
# </asp:TemplateField>
# <asp:TemplateField HeaderText="Status" ItemStyle-HorizontalAlign="Center">
# <ItemTemplate>
# <asp:Label ID="lblStatus" runat="server" Text='<%# Eval("LeadStatus") %>'
# CssClass="repGridText" ToolTip='<%# "Notes: " + Eval("Comments") %>' />
# </ItemTemplate>
# </asp:TemplateField>
# <asp:TemplateField HeaderText="Customer" ItemStyle-HorizontalAlign="Left">
# <ItemTemplate>
# <asp:Label ID="lblCustomer" runat="server" Text='<%# Eval("Name") %>'
# CssClass="repGridText" ToolTip='<%# "Address: " + Eval("Add1") + " - " + Eval("City") +
# " - " + Eval("State") + " - " + Eval("Zip") %>' />
# </ItemTemplate>
# </asp:TemplateField>
# <asp:TemplateField HeaderText="Phone" ItemStyle-HorizontalAlign="Center">
# <ItemTemplate>
# <asp:Label ID="lblPhone" runat="server" Text='<%# Eval("Phone") %>'
# ToolTip='<%# "Contact: " + Eval("FirstName") + " " + Eval("LastName") %>'
# CssClass="repGridText" />
# </ItemTemplate>
# </asp:TemplateField>
# <asp:TemplateField HeaderText="Email" ItemStyle-HorizontalAlign="Center">
# <ItemTemplate>
# <asp:HyperLink ID="hlEmail" runat="server" Text='<%# Eval("Email") %>'
# CssClass="repGridLbtn" NavigateUrl='<%#"mailto:" + Eval("Email") %>' />
# </ItemTemplate>
# </asp:TemplateField>
# <asp:TemplateField HeaderText="ESM" ItemStyle-HorizontalAlign="Center">
# <ItemTemplate>
# <asp:Label ID="lblRsm" runat="server" Text='<%# Eval("EsmTerritory") %>'
# ToolTip='<%# "Agent: " + Eval("AgentName") + ", Salesperson: " + Eval("SalesPerson") %>'
# CssClass="repGridText" />
# </ItemTemplate>
# </asp:TemplateField>
# <asp:TemplateField HeaderText="Machine" ItemStyle-HorizontalAlign="Center">
# <ItemTemplate>
# <asp:LinkButton ID="lbtnMach" runat="server" Text='<%# Eval("MachModel") %>'
# CssClass="repGridLbtn" CommandName="GetMachInfo"
# ToolTip='<%# "Factory: " + Eval("Producer") %>'
# CommandArgument=<%# Eval("MachID") + "§" + Eval("Name") + "<br />" + Eval("MachModel") %> />
# </ItemTemplate>
# </asp:TemplateField>
# <asp:TemplateField HeaderText="Est. Sales" ItemStyle-HorizontalAlign="Center">
# <ItemTemplate>
# <asp:Label ID="lblEstSales" runat="server" Text='<%#string.Format("{0:C}", Eval("EstSales"))%>'
# ToolTip='<%# "Invoice Probability: " + Eval("InvProb") + "%, Chance: " +
# Eval("Chance") + "%" %>' CssClass="repGridText" />
# </ItemTemplate>
# </asp:TemplateField>
# </Columns>
# </asp:GridView>
# </div>
# </ContentTemplate>
# </asp:UpdatePanel>
答案 0 :(得分:2)
答案 1 :(得分:1)
如果网格视图在IE,Firefox和Opera上工作正常(我的意思是可见的),但在Google Chrome中没有,那么请对代码进行必要的更改:
在visible="false"
代码中添加<asp:UpdateProgress>
。