Gridview Table not visible, html does not render
I have a gridview that is bound to an objectdatasource. It is getting data, the data is in the html markup - I just can't see it!
Here is the default.aspx:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="memorywell_2._Default" %>
Memorywell Information Services
<asp:ObjectDataSource ID="resumesource" runat="server" SelectMethod="FetchAllGigs" EnablePaging="false"
DataObjectTypeName="memorywell_2DataModel.Resume" TypeName="memorywell_2DataModel.Resume">
</asp:ObjectDataSource>
<asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="false" DataSourceID="resumesource" AllowPaging="false" PageSize="10">
<EmptyDataTemplate>
No data for your query.</EmptyDataTemplate>
<Columns>
<asp:TemplateField>
<ItemTemplate>
Description: <%# Eval("Description") %>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</form>
here is the html from "view page source" on my browser:
Memorywell Information S开发者_开发知识库ervices
<div>
<table cellspacing="0" rules="all" border="1" id="GridView1" style="border-collapse:collapse;">
<tr>
<th scope="col"> </th>
</tr><tr>
<td>
Description: (Contract) Maintain 4 websites including a national site that receives 80,000 hits per month. Develop new sites and custom modules in C# and MS SQL for DotNetNuke content management system. Developing new internationally targeted community site that includes custom C# modules for product reviews.
</td>
</tr>
</table>
</form>
Based on the HTML you provided you should have a table with one cell and the text inside (see jsfiddle with your HTML)
Check if your table is inside a container (maybe some DIV) that is hidden.
精彩评论