i have a datalist,i want an add button at the end of each row,clicking wich should result in a new blank row

Recommended Answers

All 2 Replies

>i have a datalist,i want an add button at the end of each row,clicking wich should result in a new blank row

Add button into ItemTemplate.

Hi nverma ,
Do you want to add empty row to datalist at run time? If so, you need to store the data source(such as DataTable, collection etc) which is bound to the DataList in Session. As adatapost said, add a button control to the ItemTemplate appropriately. When the button is clicked, retrieve the data source from session and add an empty record to it and rebind it to DataList again.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.