Default values in a gridview
-
Monday, July 11, 2011 6:53 AM
<asp:GridView ID="grdPass" runat="server" AutoGenerateColumns="false">
<Columns>
<asp:TemplateField>
<ItemTemplate>
<asp:Label ID="lblMessage" Text="1. First <br /> 2. Second" runat="server"></asp:Label>
</ItemTemplate>
<HeaderTemplate>
<asp:Label ID="lblHeader" Text="Message" runat="server"></asp:Label>
</HeaderTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>The above gridview is blank even though default values is available.
I want to know why the gridview is not able to display with default values
Jai- Moved by Paul Zhou Tuesday, July 12, 2011 3:40 AM (From:.NET Base Class Library)
All Replies
-
Monday, July 11, 2011 12:44 PMyes it will not display any value because u did not tell that how much records it will display i mean how much rows u r going to display in the grid view because datagrid data source is null bydefault now.
amit.murli -
Tuesday, July 12, 2011 3:39 AM
Hi,
Welcome to the MSDN forum!
According to your description, I'd like to move your thread to off-topic because it is a problem related to ASP.NET. You may post thread in ASP.NET Forum. There are more experts in that forum so that you may get more useful help there.
Thank you for your posting and understanding.
Have a nice day!
Paul Zhou [MSFT]
MSDN Community Support | Feedback to us
Get or Request Code Sample from Microsoft
Please remember to mark the replies as answers if they help and unmark them if they provide no help.
