Click here to Skip to main content
16,012,025 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hello dear all of you.

how to scroll blog or news data in datagridview with attriviewts subject and create date.

thanks in advance.
Posted
Updated 28-Jun-13 0:30am
v2
Comments
Sushil Mate 28-Jun-13 8:04am    
Can you please clarify more? I'm failed to understand.
ZurdoDev 28-Jun-13 9:08am    
Need more info. Just sort by create date in your sql. Where are you stuck?

1 solution

my self solution it's used code

<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:dbJmblissConnectionString %>"
SelectCommand="SELECT [title], [news], [PostDate] FROM [tblNews]" EnableCaching="True">
</asp:SqlDataSource>
<marquee onmouseover="stop()" onmouseout="start()" margin-left="15px" direction="up" scrollamount="2" width="300" height="270" <%--behavior="alternate"--%> text-align="justify">
<div style="width:300px;font-size:17px;">

<asp:FormView ID="FormView1"
runat="server"
DataSourceID="SqlDataSource1"
AllowPaging="True" margin-left="14px" text-align="justify" >
<EditItemTemplate>
Title:
<asp:TextBox ID="TitleTextBox" runat="server" Text='<%# Bind("title") %>' />
<br /><br />
News:
<asp:TextBox ID="NewsTextBox" runat="server" Text='<%# Bind("news") %>' />
<br /><br />
PostDate:
<asp:TextBox ID="PostDateTextBox" runat="server"
Text='<%# Bind("PostDate") %>' />
<br />
<asp:LinkButton ID="UpdateButton" runat="server" CausesValidation="True"
CommandName="Update" Text="Update" />
&nbsp;<asp:LinkButton ID="UpdateCancelButton" runat="server"
CausesValidation="False" CommandName="Cancel" Text="Cancel" />
</EditItemTemplate>

<InsertItemTemplate>
Title:
<asp:TextBox ID="TitleTextBox" runat="server" Text='<%# Bind("title") %>' />
<br /><br />
News:
<asp:TextBox ID="NewsTextBox" runat="server" Text='<%# Bind("news") %>' />
<br /><br />
PostDate:
<asp:TextBox ID="PostDateTextBox" runat="server"
Text='<%# Bind("PostDate") %>' />
<br />
<asp:LinkButton ID="InsertButton" runat="server" CausesValidation="True"
CommandName="Insert" Text="Insert" />
&nbsp;<asp:LinkButton ID="InsertCancelButton" runat="server"
CausesValidation="False" CommandName="Cancel" Text="Cancel" />
</InsertItemTemplate>
<ItemTemplate>
Title:
<asp:Label ID="TitleLabel" runat="server" Text='<%# Bind("title") %>' />
<br /> <br />
News:
<asp:Label ID="NewsLabel" runat="server" Text='<%# Bind("news") %>' />
<br /> <br />
PostDate:
<asp:Label ID="PostDateLabel" runat="server" Text='<%# Bind("PostDate") %>' />
<br />
</ItemTemplate>
<PagerSettings Mode="Numeric"/>

</asp:FormView>
</div></marquee>
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900