Quantcast
Channel: Web Forms
Viewing all articles
Browse latest Browse all 23244

Add controls dynamically with validation

$
0
0

Hello all,

I want to add controls on a page dynamically when a button "Add more" is clicked. control is in form of Name/Value pair.
Both Name & Value are Textboxes. There is initially a single Pair of these 2 textboxes, but I want to add more when button gets clicked.

If user does not add any value to recently added control, then "Add more" button should be disabled. As soon as he completes entering values in both textboxes then that button get enabled. 

Finally when Finish button is clicked then they should be validated and after validation their values should be entered in database. But how we then loop through these controls.

How it can be done? Kindly help me.

Thanks


Viewing all articles
Browse latest Browse all 23244

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>