create textbox dynumicaly and add to placeholder
-
hi I want in button_click create a text box and add to placeholder. in fact, I want by each click add a textbox to my page. how? thanks
-
hi I want in button_click create a text box and add to placeholder. in fact, I want by each click add a textbox to my page. how? thanks
Use Javascript.. If you dont have any serverside code to run. Create a textbox using Javascript :
function createTextBox()
{
var tb = document.createElement('input');
tb.id = new Date().getTime().toString().substr(5) + Math.floor(Math.random() * 100).toString() + '_dyntextbox'; //Random ID
tb.type = 'text';
document.appendChild(tb);}
This will create a textbox dynamically in the document. :thumbsup:
Abhishek Sur **Don't forget to click "Good Answer" if you like this Solution.
My Latest Articles-->** Microsoft Bing MAP using Javascript
CLR objects in SQL Server 2005
Uncommon C# Keywords/xml>