Click here to Skip to main content
15,881,248 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
Hi friends,

in my application i have a modal popup which contains ajax tab container with 2 tab controls.
one tab control had some controls like labels & text boxes and another tab control had crystal report.
I want to read label and text values in javascript function. Could any one suggest me.


thanks
Posted
Updated 4-May-12 1:42am
v5
Comments
demouser743 4-May-12 6:14am    
Can you post your design
demouser743 4-May-12 7:36am    
Where is your design related to AJAX tab control. Post it in the question by updating rather than posting as comment

1 solution

Try this

C#
 <script type="text/javascript">
       function alertname(username) {        
        alert(username);
        }
    </script>

<asp:TextBox ID="txtusername" runat="server" onblur="alertname(this.value)">
 
Share this answer
 
v3
Comments
kishorekke 4-May-12 8:01am    
hi friend.. i used like that but not working..


function calculateTime(strName) {

debugger

//Totals

var lbl=$find("tabMain$TabMTQAHours$lblTotalHoursWorked");

//var lbl=$find("tabMain_TabMTQAHours_lblTotalHoursWorked");

//var totalhours=document.getElementById("tabMain_TabMTQAHours_lblTotalHoursWorked").innerText;

alert(lbl.innerHTML);
demouser743 5-May-12 5:44am    
Try this

<asp:TextBox ID="txtuser" onblur="GetValue(this.value)" runat="server">

<script type="text/javascript">
function GetValue(username) {
alert(username);
}
</script>

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