EditTemplate (the problem is the same in the DataGrid). I want to have
access to this controls, using javascript, but
i can't. How can i do this?
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Sunny SharmaPosted Aug 10, 2013, 6:27 AM
check the View Source (CTRL+U) of the rendered html page, may be it's renamed by the server like DataList_ID_ctl01_txt1.
Here 01 is the repeat count starting with 01 of the controls inside DataList.
try this:
document.getElementById('myDataList_ctl01_txt1').value='newValue';
Please share your complete aspx code having issues yet.
Hope it helps.
Happy Coding :)
Pradip DaingadePosted Aug 10, 2013, 5:41 AM
...."Test"...>"txt1"runat=server>..."txt2"runat=server>Sunny SharmaPosted Aug 10, 2013, 5:33 AM
can you share your aspx code?