Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Feb 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Object Required error

    Dear Sir/madam

    I'm working in ASP .net .
    I have used javascript.

    I want to visible the panel after clicking the Hyperlink
    I used this statement

    document.getElementById('Panel2').style.visibility ="visible";
    But it doesn't work.
    Plz help me.


    My code is


    <html xmlns="http://www.w3.org/1999/xhtml" >
    <head runat="server">
    <title>Untitled Page</title>
    <script language ="javascript" type ="text/javascript" >

    function Connect()
    {

    document.getElementById('Panel2').style.visibility ="visible";
    alert('abc');
    }
    function Tare()
    {
    alert('abc');
    //ac.Tare();

    }

    function AcquireWeight()
    {

    alert('abc');

    }

    </script>
    </head>
    <body>
    <form id="form1" runat="server">
    <div>
    <asp:Panel ID="Panel1" runat="server" Height="50px" Width="125px">
    <a href="#" onclick="javascript:Connect()"> Connect </a>
    </asp:Panel>

    <asp:Panel ID="Panel2" runat="server" Height="50px" Width="125px" Visible="False" >
    <a href="#" onclick="javascript:AcquireWeight"> AcquireWeight </a>
    <a href="#" onclick="javascript:Tare()"> Tare </a>
    </asp:Panel>


    </div>
    </form>
    </body>
    </html>

  • #2
    Supreme Master coder! abduraooft's Avatar
    Join Date
    Mar 2007
    Location
    N/A
    Posts
    14,865
    Thanks
    160
    Thanked 2,224 Times in 2,211 Posts
    This is Client-side-development's sub-forum, so please post the client side html output taken from your browser's "view source" option. Also, use [CODE][/CODE] tags to wrap your code while posting here.
    Thanks.
    The Dream is not what you see in sleep; Dream is the thing which doesn't let you sleep. --(Dr. APJ. Abdul Kalam)


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •