Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7670053
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T15:44:04+00:00 2026-05-31T15:44:04+00:00

Button <asp:Button ID=btnAdd runat=server Text=Add/> Label <asp:Label ID=label1 runat=server></asp:Label> Set button visible when the

  • 0
Button 

<asp:Button ID="btnAdd" runat="server" Text="Add"/>

Label 

<asp:Label ID="label1" runat="server"></asp:Label>

Set button visible when the label1.text is different from “”

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T15:44:05+00:00Added an answer on May 31, 2026 at 3:44 pm

    I dont see you the label will get text during runtime unless it happens with jquery. So i will go with this approach:

    Firstly add a style attribute to the label like so:

    <asp:Label ID="label1" runat="server" style="display:none;"></asp:Label>
    

    And then when the page loads do the following:

    $(document).ready(function () 
    { 
      if ($("#label1").text() == "")
      { 
        $("#btnAdd").show();
      }
    });
    

    The question is very unclear though.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

How change visibility of gridview template field on OnClick event. <gaia:Button ID=btnAdd runat=server Text=Add
I want to trigger on click of a button this: <asp:Button runat=server ID=submit Text=Submit
i have asp text box and button control. <asp:TextBox ID=txtFName runat=server CssClass=sfInputbox></asp:TextBox> <asp:Button runat=Server
I have an asp.net button control on the page. <asp:Button ID=btnFinishReceiving runat=server Text=Finished Receiving
How do I escape apostrophes / single quotes in ASP.net XML? <asp:Button ID=myButton runat=server
i have asp button like this: <asp:Button ID=ImportToDB runat=server OnClick=ImportToDB_Click /> And i need
I am showing my code first <div class = buttonsHolder> <asp:Button runat = server
Does anyone know a way to make an asp button... <asp:button runat=server>Button1</asp:button> resemble an
I have an ASP button that lookts like this: <asp:Button ID=btnReset runat=server OnClientClick =
I have a ASP.NET page with an asp:button that is not visible. I can't

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.