Better tool for selection - Datagrid or DataList?

J

jonefer

After the user searches and is presented with a list of results - which is
the better tool for clicking to get a "details" page...?

If it is the DataGrid, how do I recoginize selection? (Doesn't highlight
when clicked)

If it is the DataList, I'm having problems with the same record repeating
over and over again... instead of showing all the different records...
 
P

Phillip Williams

Hi Jonefer,

The datagrid has 2 properties:
1- SelectedIndex:
http://msdn.microsoft.com/library/d...ebcontrolsdatagridclassselectedindextopic.asp

2- SelectedItemStyle:
http://msdn.microsoft.com/library/d...ntrolsdatagridclassselecteditemstyletopic.asp
And an event named SelectedIndexChanged
http://msdn.microsoft.com/library/d...asedatalistclassselectedindexchangedtopic.asp

If you use any combinations of those members you can select a row on datagrid.

You can also do that using Javascript on the client as in this demo:
http://www.societopia.net/samples/dataGrid_5c.aspx

The datalist too has similar properties and events as the datagrid. I have
a sample using the datalist selectedIndex to highlight the select row:
http://www.societopia.net/Samples/DataList_Hierarchy.aspx
 

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

Members online

Forum statistics

Threads
474,139
Messages
2,570,805
Members
47,356
Latest member
Tommyhotly

Latest Threads

Top