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 8093989
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T20:39:02+00:00 2026-06-05T20:39:02+00:00

I’ve read other posts with similar names, but none of their problems matched mine

  • 0

I’ve read other posts with similar names, but none of their problems matched mine nor did their solutions solve mine. I have a gridview with a linkbutton field which displays a modal(ish) box. Because the linkbutton field calls server side instead of client-side I couldn’t get a JQUERY modal form to work. Instead, on linkbutton click I display an asp panel with CSS to make it look modal(ish). Within that panel I have an asp button that used to exit the modal by setting panel.visible = false.

However, when I click on the “exit” button it never calls the btnExitProject_Click sub procedure which hides the panel. Usually in design mode of Visual Studio I can double click on a button and it will show the “onClick” event in the server side code; however, right now it takes me to the page_load sub. I’m not sure what’s going on. Other buttons on the page, outside of the panel work just fine and the “Join Project” button (see pic) which calls a jquery function works just fine as well.

<asp:Panel ID="pnlProjectInfo" runat="server" Visible="false">
    <div class="overlay"></div>
    <div class ="projectPanel">

        <span class="spanStyle">Project Code: </span><asp:Label ID="lblProjectCode" runat="server" Text="[proj code]" CssClass="lblStyle1"></asp:Label><br /><br />
        <span class="spanStyle">Entry Date: </span><asp:Label ID="lblEntryDate" runat="server" CssClass="lblStyle1"></asp:Label><br /><br />
        <span class="spanStyle">Project: </span><br />
        <asp:TextBox ID="tbProject" runat="server" Width="500px" CssClass="tbStyle1"></asp:TextBox><br />
        <span class="spanStyle">Organization: </span><br />
        <asp:TextBox ID="tbOrgName" runat="server" Width="395px" CssClass="tbStyle1" Enabled="false"></asp:TextBox><br />
        <span class="spanStyle">Project Leader: </span><br /><asp:TextBox ID="tbProjLeader" runat="server" Width="196px" CssClass="tbStyle1"></asp:TextBox><br />
        <span class="spanStyle">Description: </span><br /><asp:TextBox ID="tbDescription" runat="server" 
            Height="50px" Width="500px" TextMode="MultiLine" CssClass="tbStyle1"></asp:TextBox><br />
        <span class="spanStyle">Comment: </span><br /><asp:TextBox ID="tbComment" runat="server" 
            Height="50px" Width="500px" TextMode="MultiLine" CssClass="tbStyle1"></asp:TextBox><br />

        <br />


        <span class="spanStyle">Project Members: </span>
        <br />

         <asp:GridView ID="gvProjectMembers" runat="server" AutoGenerateColumns="False" 
            CellPadding="3" 
            Width="512px" Font-Names="Arial" GridLines="Vertical" BackColor="White" 
            BorderColor="#333333" BorderStyle="Solid" BorderWidth="1px" 
            CssClass="projMembersGV">
            <RowStyle BackColor="#ecf1ef" ForeColor="Black" HorizontalAlign="Center" 
                 VerticalAlign="Top" />
            <Columns>
                <asp:BoundField DataField="individual_first_name" HeaderText="First Name" />
                <asp:BoundField DataField="individual_last_name" HeaderText="Last Name" />
                <asp:BoundField DataField="percentage_effort" HeaderText="Effort"  />
                <asp:BoundField DataField="participation_description" 
                    HeaderText="Participation" />
                <asp:BoundField DataField="active_indicator" HeaderText="Active" />
                <asp:CommandField ButtonType="Button" ShowEditButton="True" />
            </Columns>
            <FooterStyle BackColor="#CCCCCC" ForeColor="Black" />
            <PagerStyle BackColor="#999999" ForeColor="Black" HorizontalAlign="Center" />
             <EmptyDataTemplate>
                 No members assinged to this project in the database.
             </EmptyDataTemplate>
            <SelectedRowStyle BackColor="#008A8C" Font-Bold="True" ForeColor="White" />
            <HeaderStyle BackColor="#333333" Font-Bold="True" ForeColor="White" />
            <AlternatingRowStyle BackColor="#ecf1ef" />
        </asp:GridView>
         <br />
        <button id="create-user" type="button">Join Project</button> <!-- displays a jquery modal -->
        <asp:Button ID="btnExitProject" runat="server" Text="Close" CssClass="btnClose" CausesValidation="false" Enabled="true" />





    </div>
</asp:Panel>

Here’s a look of the panel:
Modal Panel

  • 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-06-05T20:39:03+00:00Added an answer on June 5, 2026 at 8:39 pm

    I decided to use JQuery instead of a server-side onclick event. This actually proved to be a great idea because the response time is much much quicker.

    Replaced my btnExitProject with:

    <input type="button" id="close_modal" value="Close"/> 
    

    I then added some jquery to the top of my page within the $(document).ready(function() {

     $("#close_modal")
            .button()
            .click(function() {
                $("#<%=pnlProjectInfo.ClientID %>").hide();
            });
    

    This just says that when the button with the “close_modal” id is clicked I need to hide my asp panel. Because the panel is asp the ID given to it in the code is not what the actual ID is read as, thus I had to put "#<%=pnlProjectInfo.ClientID %>" to reference the panel.

    Thanks for your help guys!

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

Sidebar

Related Questions

link Im having trouble converting the html entites into html characters, (&# 8217;) i
I want to count how many characters a certain string has in PHP, but
I have a French site that I want to parse, but am running into
I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
This could be a duplicate question, but I have no idea what search terms
I know there's a lot of other questions out there that deal with this
I'm trying to convert HTML to plain text. I get many &\#8217; &\#8220; etc.
I want to construct a data frame in an Rcpp function, but when I
I need to clean up various Word 'smart' characters in user input, including but
I have a bunch of posts stored in text files formatted in yaml/textile (from

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.