add some data in temporary table (c# in memory table) and send code , i will run and check then i will tell u further
On Jun 24, 11:39 am, Yogesh Dige <[email protected]> wrote: > This is the code where i used Empty data text and empty data row to > show the No records if the data source which i bind is not containg > the data. > i googled and tried still facing tha same problem. > for one page it is working but if i called the same page on th click > of another button next time with hiding some rows and columns then > this property is not working. > > <div style="height: 245px; overflow: auto; width: 100%;"> > <asp:GridView ID="gvBookingDetails" runat="server" > BackColor="White" BorderColor="#DEDFDE" > BorderStyle="None" BorderWidth="1px" > CaptionAlign="Top" CellPadding="4" ForeColor="Black" > GridLines="Vertical" Height="6px" Width="100%" > OnRowCreated="gvBookingDetails_RowCreated" > Font-Size="Small" > OnRowDataBound="gvBookingDetails_RowDataBound" > AutoGenerateColumns="False" > Font-Names="Tahoma" > OnDataBinding="gvBookingDetails_DataBinding" TabIndex="8" > EmptyDataText="There are no records.!!" > EmptyDataRowStyle-CssClass="EmptyData"> > <EmptyDataTemplate> "There are no records.!!" > </EmptyDataTemplate> > <FooterStyle BackColor="#CCCC99" /> > <RowStyle BackColor="#BADAF6" Wrap="False" /> > <Columns> > <%-- <asp:TemplateField HeaderText="Sr.No."> > <ItemTemplate> > <%# Container.DataItemIndex + 1 %> > </ItemTemplate> > <HeaderStyle HorizontalAlign="Left" > VerticalAlign="Middle" Width="4%"></HeaderStyle> > <ItemStyle HorizontalAlign="Left" > VerticalAlign="Middle"></ItemStyle> > </asp:TemplateField>--%> > <asp:TemplateField HeaderText="Select"> > <ItemTemplate> > <asp:Literal > ID="RadioButtonMarkup" runat="server"> > </asp:Literal> > </ItemTemplate> > <ItemStyle Width="30px" > HorizontalAlign="Left" /> > </asp:TemplateField> > <asp:BoundField DataField="BookingDate" > HeaderText="Booking Date"> > <ItemStyle Wrap="False" Width="80px" > HorizontalAlign="Left" /> > </asp:BoundField> > <asp:BoundField DataField="FromTime" > HeaderText="From"> > <ItemStyle Wrap="False" Width="80px" > HorizontalAlign="Left" /> > </asp:BoundField> > <asp:BoundField DataField="ToTime" > HeaderText="To"> > <ItemStyle Wrap="False" Width="80px" > HorizontalAlign="Left" /> > </asp:BoundField> > <asp:BoundField DataField="LocationName" > HeaderText="Location" SortExpression="LocationName"> > <ItemStyle Font-Names="Tahoma" Font- > Size="Small" HorizontalAlign="Left" /> > </asp:BoundField> > <asp:BoundField DataField="Room" > HeaderText="Room"> > <ItemStyle Wrap="True" Width="130px" > VerticalAlign="Middle" HorizontalAlign="Left" /> > </asp:BoundField> > <asp:BoundField DataField="HostedBy" > HeaderText="Host"> > <ItemStyle Wrap="True" Width="130px" > HorizontalAlign="Left" /> > </asp:BoundField> > <asp:BoundField DataField="Subject" > HeaderText="Subject"> > <ItemStyle Wrap="True" Width="130px" > HorizontalAlign="Left" VerticalAlign="Middle" /> > </asp:BoundField> > <asp:BoundField DataField="Remarks" > HeaderText="Remarks"> > <ItemStyle Wrap="True" Width="150px" > HorizontalAlign="Left" VerticalAlign="Middle" /> > </asp:BoundField> > <asp:BoundField DataField="Requestedby" > HeaderText="Requested by"> > <ItemStyle Wrap="True" Width="150px" > VerticalAlign="Middle" HorizontalAlign="Left" /> > </asp:BoundField> > </Columns> > <PagerStyle BackColor="#F7F7DE" > ForeColor="Black" HorizontalAlign="Right" Wrap="True" /> > <SelectedRowStyle BackColor="#CE5D5A" Font- > Bold="True" ForeColor="White" /> > <HeaderStyle BackColor="#337FC2" Font- > Bold="True" ForeColor="White" CssClass="Freez" /> > <AlternatingRowStyle BackColor="White" > Wrap="False" /> > <EditRowStyle Wrap="True" /> > <EmptyDataRowStyle Width="1px" > CssClass="EmptyData" /> > </asp:GridView> > </div>
