Click here to Skip to main content
15,908,675 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionHow to convert any file to .pdf using Adobe PDF Printer ? Pin
Krushna Sahu25-Mar-09 3:28
Krushna Sahu25-Mar-09 3:28 
AnswerRe: How to convert any file to .pdf using Adobe PDF Printer ? Pin
Yusuf25-Mar-09 4:40
Yusuf25-Mar-09 4:40 
GeneralRe: How to convert any file to .pdf using Adobe PDF Printer ? Pin
Krushna Sahu25-Mar-09 19:36
Krushna Sahu25-Mar-09 19:36 
Questionupdate panel validation problem Pin
Mogaambo25-Mar-09 3:01
Mogaambo25-Mar-09 3:01 
AnswerRe: update panel validation problem Pin
Yusuf25-Mar-09 4:41
Yusuf25-Mar-09 4:41 
QuestionUpdatePanel for Buttion Pin
antony beula25-Mar-09 2:56
antony beula25-Mar-09 2:56 
AnswerRe: UpdatePanel for Buttion Pin
Viral Upadhyay25-Mar-09 3:47
Viral Upadhyay25-Mar-09 3:47 
QuestionDon`t know whether its a bug in Gridviews empty data template Pin
www.Developerof.NET25-Mar-09 2:48
www.Developerof.NET25-Mar-09 2:48 
Hi all,

I am finding a tough time solving this problem, but i am not able to understand this weird functionality.

I have a grid view in my aspx as:

<asp:GridView ID="Grv_Loc_wise_stk" runat="server" AutoGenerateColumns="false" Width="946px" AllowSorting="True">
<AlternatingRowStyle CssClass="datagrid_row" />
<RowStyle CssClass="datagrid_row1" />
<HeaderStyle CssClass="datagrid_heading" />
<Columns>
<asp:CommandField ShowSelectButton="True" />
<asp:BoundField DataField="code" HeaderText="Code" />
<asp:BoundField DataField="item" HeaderText="Material Name" />
<asp:BoundField DataField="unit" HeaderText="Units" />
<asp:BoundField DataField="qty" HeaderText="Qty." />
</Columns>
<EmptyDataTemplate>
<asp:Label ID="Label1" runat="server" Font-Size="Small" ForeColor="DarkOrange" Text="<b>Sorry!!! No Records Available.</b>"></asp:Label>
</EmptyDataTemplate>
</asp:GridView>


After binding to gridview and in case no data is fetched, the grid doesn`t show up the empty data template. When i checked the html generated , the grid view is generated as

<table cellspacing="0" rules="all" border="1" id="Grv_Loc_wise_stk" style="width:946px;border-collapse:collapse;">
<tr>

</tr>
</table>


There are no td tags generated.Where it should have been

<table cellspacing="0" rules="all" border="1" id="Grv_Loc_wise_stk" style="width:946px;border-collapse:collapse;">
<tr>
<td>
<span>Sorry!!! No Records Available.</span></td>
</tr>
</table>


what could be the problemConfused | :confused: Confused | :confused: Confused | :confused:

When you fail to plan, you are planning to fail.
AnswerRe: Don`t know whether its a bug in Gridviews empty data template Pin
samerh25-Mar-09 4:13
samerh25-Mar-09 4:13 
GeneralRe: Don`t know whether its a bug in Gridviews empty data template Pin
www.Developerof.NET25-Mar-09 4:28
www.Developerof.NET25-Mar-09 4:28 
GeneralRe: Don`t know whether its a bug in Gridviews empty data template Pin
tech60325-Mar-09 15:43
tech60325-Mar-09 15:43 
GeneralRe: Don`t know whether its a bug in Gridviews empty data template Pin
www.Developerof.NET25-Mar-09 22:15
www.Developerof.NET25-Mar-09 22:15 
Questionchart in asp.net Pin
Jooda Funsho Joseph25-Mar-09 2:44
Jooda Funsho Joseph25-Mar-09 2:44 
AnswerRe: chart in asp.net Pin
Viral Upadhyay25-Mar-09 3:21
Viral Upadhyay25-Mar-09 3:21 
AnswerRe: chart in asp.net Pin
www.Developerof.NET25-Mar-09 3:24
www.Developerof.NET25-Mar-09 3:24 
AnswerRe: chart in asp.net Pin
samerh25-Mar-09 4:19
samerh25-Mar-09 4:19 
QuestionSQL database Pin
kibromg25-Mar-09 2:31
kibromg25-Mar-09 2:31 
AnswerRe: SQL database Pin
Brian W King25-Mar-09 3:23
Brian W King25-Mar-09 3:23 
GeneralRe: SQL database Pin
kibromg25-Mar-09 3:28
kibromg25-Mar-09 3:28 
GeneralRe: SQL database Pin
Brian W King25-Mar-09 3:46
Brian W King25-Mar-09 3:46 
GeneralWhy Dot Taking Url Pin
MallikarjunaGupta25-Mar-09 2:26
MallikarjunaGupta25-Mar-09 2:26 
GeneralRe: Why Dot Taking Url Pin
EliottA25-Mar-09 2:36
EliottA25-Mar-09 2:36 
JokeRe: Why Dot Taking Url Pin
Greg Chelstowski25-Mar-09 5:14
Greg Chelstowski25-Mar-09 5:14 
QuestionSQL time out exception because of datareader Pin
pavan.kumar,sai25-Mar-09 2:14
pavan.kumar,sai25-Mar-09 2:14 
AnswerRe: SQL time out exception because of datareader Pin
Ashfield25-Mar-09 2:26
Ashfield25-Mar-09 2:26 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.