Click here to Skip to main content
15,881,380 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
here is jquery code
JavaScript
function pageLoad()
{
    //--------------company name-------------
    $("#nametextbox1").dblclick(function()
    {
        var selectedEffect = 'slide';
        var options = {};
        $( "#effect" ).toggle(selectedEffect, options, 500 );
    });

    $("#btnsavcm").click(function(event)
    {
        $("#effect").hide('slide');
    });
}


here is the asp.net code
<%@ Register assembly="textboxforname" namespace="textboxforname" tagprefix="cc1" %>

XML
<cc1:nametextbox ID="nametextbox1" runat="server" textcase="none"
                       targetlabel="Company Name" onload="nametextbox1_Load" ></cc1:nametextbox>


I want to change my code like that
JavaScript
function pageLoad()
{
    //--------------company name-------------
    function togglecall(txtname,effect)
    {
        var selectedEffect = 'slide';
        var options = {};
        $( "#effect" ).toggle(selectedEffect, options, 500 );
    }
}

ASP.NET
<cc1:nametextbox ID="nametextbox1" runat="server" textcase="none" targetlabel="Company Name" onload="nametextbox1_Load" ondblclick="togglecall(this,effect)" ></cc1:nametextbox>
Posted
Updated 8-Oct-13 3:12am
v2
Comments
Eduard Keilholz 8-Oct-13 9:13am    
And what is your question?
Palash Mondal_ 8-Oct-13 10:34am    
Not clear what is your requirement over here???
ZurdoDev 8-Oct-13 10:34am    
Where are you stuck?
MAYANK GEETE 9-Oct-13 3:56am    
TOGGLE NOT WORKING WHEN I CHANGE MY CODE ...LIKE THIS ..
Palash Mondal_ 9-Oct-13 10:21am    
Why are you passing the two variables this & effect in your togglecall() function, when you are not using them all all??

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