473,385 Members | 1,536 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

bgcolor of repeater row

when I click the button in datarepeater, I would like to set the bgcolor of the row to red.
I don't know how to get the reference to that row.

Something like this?
Private Sub rprPlists_ItemCommand(ByVal source As Object, ByVal e As System.Web.UI.WebControls.RepeaterCommandEventArgs ) Handles rprPlists.ItemCommand

If e.CommandSource.GetType.Name.ToString() = "Button" Then

e.row.bgcolor=color.red
pnlTest.visible=true

end if

Then I show test panel and after click the cancel button on that panel, I would like that the coloured row in my datarepeater is set back to white.

Any example?

Thank you,
Simon

Nov 19 '05 #1
3 1270
Simon,

I would do all that on client side with javascript. This needs a bit of understanding of page object model. If it is not suitable for you, you can do it on server side.

To get to the row use e.Item. Look up the help and try.

Eliyahu

"simon" <si*********@stud-moderna.si> wrote in message news:Oe***************@TK2MSFTNGP15.phx.gbl...
when I click the button in datarepeater, I would like to set the bgcolor of the row to red.
I don't know how to get the reference to that row.

Something like this?
Private Sub rprPlists_ItemCommand(ByVal source As Object, ByVal e As System.Web.UI.WebControls.RepeaterCommandEventArgs ) Handles rprPlists.ItemCommand

If e.CommandSource.GetType.Name.ToString() = "Button" Then

e.row.bgcolor=color.red
pnlTest.visible=true

end if

Then I show test panel and after click the cancel button on that panel, I would like that the coloured row in my datarepeater is set back to white.

Any example?

Thank you,
Simon

Nov 19 '05 #2
Hi, eliyahu,

do you have any example?

I can't find the reference to the repeater row from e.item

Thank you,
Simon
"Eliyahu Goldin" <re*************@monarchmed.com> wrote in message news:eO**************@TK2MSFTNGP10.phx.gbl...
Simon,

I would do all that on client side with javascript. This needs a bit of understanding of page object model. If it is not suitable for you, you can do it on server side.

To get to the row use e.Item. Look up the help and try.

Eliyahu

"simon" <si*********@stud-moderna.si> wrote in message news:Oe***************@TK2MSFTNGP15.phx.gbl...
when I click the button in datarepeater, I would like to set the bgcolor of the row to red.
I don't know how to get the reference to that row.

Something like this?
Private Sub rprPlists_ItemCommand(ByVal source As Object, ByVal e As System.Web.UI.WebControls.RepeaterCommandEventArgs ) Handles rprPlists.ItemCommand

If e.CommandSource.GetType.Name.ToString() = "Button" Then

e.row.bgcolor=color.red
pnlTest.visible=true

end if

Then I show test panel and after click the cancel button on that panel, I would like that the coloured row in my datarepeater is set back to white.

Any example?

Thank you,
Simon

Nov 19 '05 #3
Property ItemType tells you what is the type of the item. You won't find word "row" simply because repeater items don't have to look like rows. What exactly is in the item depends on your ItemTemplate. If you want table-like rows, use a datagrid.

Eliyahu

"simon" <si*********@stud-moderna.si> wrote in message news:u8******************@TK2MSFTNGP10.phx.gbl...
Hi, eliyahu,

do you have any example?

I can't find the reference to the repeater row from e.item

Thank you,
Simon
"Eliyahu Goldin" <re*************@monarchmed.com> wrote in message news:eO**************@TK2MSFTNGP10.phx.gbl...
Simon,

I would do all that on client side with javascript. This needs a bit of understanding of page object model. If it is not suitable for you, you can do it on server side.

To get to the row use e.Item. Look up the help and try.

Eliyahu

"simon" <si*********@stud-moderna.si> wrote in message news:Oe***************@TK2MSFTNGP15.phx.gbl...
when I click the button in datarepeater, I would like to set the bgcolor of the row to red.
I don't know how to get the reference to that row.

Something like this?
Private Sub rprPlists_ItemCommand(ByVal source As Object, ByVal e As System.Web.UI.WebControls.RepeaterCommandEventArgs ) Handles rprPlists.ItemCommand

If e.CommandSource.GetType.Name.ToString() = "Button" Then

e.row.bgcolor=color.red
pnlTest.visible=true

end if

Then I show test panel and after click the cancel button on that panel, I would like that the coloured row in my datarepeater is set back to white.

Any example?

Thank you,
Simon

Nov 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Ed Allan | last post by:
http://ejaconsulting.com/nestedrepeater/NestedRepeater.txt >-----Original Message----- >Doh! The HTML has all been rendered . . . > >Right click on this link and select 'Save target as ..' >to...
8
by: Invalidlastname | last post by:
Hi, We are developing an asp.net application, and we dynamically created certain literal controls to represent some read-only text for certain editable controls. However, recently we found an issue...
0
by: Amir | last post by:
Hi every one This is the problem: I have a UserControl that contains a Repeater and a few LinkButton. The Repeater generate some linkButton. I use this control for implementing paging solution...
3
by: sorCrer | last post by:
Hi All, Posted after extensive searching! I have a nested repeater control as follows: (Simplified ;-)) <table> <asp:repeater id=parent onItemDataBound=createChild> <tr><td>Level...
8
by: I am Sam | last post by:
Hi everyone, This problem is making me old. I don't want to get any older. I have a multi-nested repeater control as follows: <asp:Repeater ID="clubRep1" Runat="server">...
1
by: olduncleamos | last post by:
Hello all, I am experimenting with the repeater control and ran into something that I wasn't expecting. I would appreciate if the experts can confirm or correct my understanding. Here is a...
2
by: GD | last post by:
I'd like to use a Repeater to display data coming back from a cross-tab report. Because it's a cross-tab, I generally don't know how many columns are coming back. They do follow a certain format: ...
8
by: fernandezr | last post by:
I would like to use a user control as a template inside a repeater. Some of the fields in the control should be hidden depending on whether or not there is data. I'm still a ASP .Net newbie so the...
0
by: uncensored | last post by:
Hello everyone, I'm fairly new at .Net and I have a repeater inside a repeater problem. I will attach my code to this message but basically what I am able to tell when I run my page it tells me...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.