highlighting arow--urgent

G

Guest

how to highlight a row of my datagrid (web) .

i dont want to use select button.

upon clicking on the row , it shouls be highlighted and
cursor shouls remain in the same row.

how to acheive it?
plz help me out
 
D

Dave Davidson

I'm not sure there is a way to highlight a row in the
DataGrid control supplied in .NET. You could try
inserting events as attributes, but I'm not sure if it's
possible.

We wrote our own grid control specific to our needs and
used three styles to represent normal rows, selected rows,
and the currently selected (highlighted) row. Then we
used the onclick event to change the class of the row when
clicked, keeping track of the last row highlighted (in
JavaScript) so it could be reset. We found that an
onclick event on every row really slowed down rendering of
the page with big grids, so we moved the onclick event to
the table and relied on event bubbling/cascading to catch
it.

Also, Infragistics has a very good grid control for
ASP.NET that will do what you want and more. Check out
http://www.infragistics.com.

- Dave Davidson (MCP)
 
G

George Durzi

You're gonna have to prbly use DHTML behaviours. There's some stuff on MSDN
that shows how. I personally haven't worked with that
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top