Hi kankon,
You need to set the Text inside HTML SPAN and set its color.
Check this example.
HTML
<div class="marquee" style="color: #000000">
<marquee onmouseover="this.stop();" onmouseout="this.start();" scrolldelay="4" scrollamount="4" behavior="scroll" direction="Right">
<asp:Repeater ID="Repeater2" runat="server" >
<ItemTemplate>
<asp:HyperLink ID="HyperLink2" runat="server" Text='<%# String.Format("<span style=color:red >{0}</span> - {1}", Eval("Name"), Eval("chat")) %>' ></asp:HyperLink>
</ItemTemplate>
</asp:Repeater>
</marquee>
</div>
Code
C#
protected void Page_Load(object sender, EventArgs e)
{
if (!this.IsPostBack)
{
System.Data.DataTable dt = new System.Data.DataTable();
dt.Columns.Add("Name");
dt.Columns.Add("Chat");
dt.Rows.Add("ASPSnippets", "Chat 1");
dt.Rows.Add("ASPForums", "Chat 2");
this.Repeater2.DataSource = dt;
this.Repeater2.DataBind();
}
}
VB.Net
Protected Sub Page_Load(sender As Object, e As EventArgs) Handles Me.Load
If Not Me.IsPostBack Then
Dim dt As Data.DataTable = New Data.DataTable()
dt.Columns.Add("Name")
dt.Columns.Add("Chat")
dt.Rows.Add("ASPSnippets", "Chat 1")
dt.Rows.Add("ASPForums", "Chat 2")
Me.Repeater2.DataSource = dt
Me.Repeater2.DataBind()
End If
End Sub
Screenshot