Click here to Skip to main content
15,886,258 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
i have a page,where i am using bootstrap modal,

please find page architecture sample,

<pre lang="HTML"><mypage>
<repeater>
<a >triggers modalbox1</>
     <modalbox1>  
     <updatepanel>
      texbox
      <a>triggers modal 2</a>
      </updatepanel>
     </modalbox1>
</repeater>

<modalbox2>
<updatepanel>
<repeater>select button</repeater>
</updatepanel>
</modalbox2>
<mypage>



i want whenever user select an item from repeater in Modal2 , value should be updated in textbox of Modal1, i have tried following javascript

JavaScript
function setJobID(idcontrol)
    {

   
        var controlToSet =document.getElementById(       document.getElementById('txtHiddenID').Value);
        var mycontrol = document.getElementById(idcontrol);       
        controlToSet.Value = mycontrol.innerText.toString();
        alert(controlToSet.Value);       
    }


in the above code alertShows me correct value, but its not getting updated/displayed in textbox of Modal1,

Can anybody help me wit this?
Posted
Updated 4-Dec-15 0:59am
v2
Comments
[no name] 1-Dec-15 1:49am    
Make sure that you are getting correct value in "mycontrol". If it is null then setting value won't work. Secondly what is value in "idcontrol" - is that correct one?
Keith Barrow 4-Dec-15 7:01am    
I'm with Manas_Kumar on this - without knowing what idcontrol is, and therefore mycontrol, it's pretty hard to tell what is going wrong.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900