Aarti helkar
Answered On : Apr 9th, 2012
Datalist is used to just read only purpose where data in table format.
where a repeater has no such format to store the data.
In repeater we can put data in any where in random format.
The Repeater control does not have any built-in layout or style. We are forced to specify all formatting-related HTML elements and style tags. On the other hand, a DataList control provides more flexibility to display data in a desired layout. It also provides data selection and editing capabilities. How does it do it?
Well, in addition to the five templates (Item Template, AlternatingItem Template, Separator Template, Header Template, Footer Template that a repeater has, the DataList control has two more templates: SelectedItemTemplate, and EditItemTemplate. These templates are useful for allowing data selection and data editing functionalities.
Login to rate this answer.