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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T17:44:29+00:00 2026-05-25T17:44:29+00:00

How can i pass value from grid view to a pop up in client

  • 0

How can i pass value from grid view to a pop up in client side. I have a edit button in the grid view and when user clicks that the value(EditExpiresBy) from selected row should be in a text box in the pop up.

<asp:Panel ID="EditPanel" runat="server">
            <asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server">
            </asp:ToolkitScriptManager>
            <asp:UpdatePanel ID="UpdatePanel1" runat="server">
                <ContentTemplate>
        <asp:TextBox ID="txt_EditExpiresBy" runat="server" ></asp:TextBox>

                    <asp:Button ID="btn_EditSave" runat="server" Text="Save" onclick="btn_EditSave_Click" />

                </ContentTemplate>
            </asp:UpdatePanel>
        </asp:Panel>

and a PopupControlExtender.

How can I pass the value in client side. help needed

  • 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-25T17:44:30+00:00Added an answer on May 25, 2026 at 5:44 pm

    One way to do this is to have a DetailsView that is linked to the SelectedValue property of your GridView. You can put the DetailsView in the popup, and it will display whatever was selected in the GridView

    Sample DetailsView Note: you would be putting this in place of the txt_EditExpiresBy TextBox control

    <asp:DetailsView ID="detailsView" runat="server" AutoGenerateRows="False" 
        DataKeyNames="yourIDField" DataSourceID="detailsSqlDataSource" 
        Height="50px" Width="287px" >
        <Fields>
            <asp:BoundField DataField="ExpiresBy" HeaderText="Expires By" 
                SortExpression="ExpiresBy" />
            <%--Whatever other fields you want to include--%>
        </Fields>
    </asp:DetailsView>
    

    Sample Data source (for the DetailsView)

    <asp:SqlDataSource ID="detailsSqlDataSource" runat="server" 
        ConnectionString="Your Connection String" SelectCommand="SELECT [ExpiresBy] FROM [tableName] WHERE yourTableID = @yourTableID">
        <SelectParameters>
            <asp:ControlParameter ControlID="yourGridView" Name="yourTableID" 
                PropertyName="SelectedValue" />
        </SelectParameters>
    </asp:SqlDataSource>
    

    See the ControlParameter in this DataSource looks at the ID of the row that was selected in the GridView and uses that to populate the DetailsView.

    Let me know if any of this is not clear and I’ll try to explain myself better, this is just the way I usually do it.

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

Sidebar

Related Questions

How can I pass a variable value from a template using JavaScript without using
How can I pass the result from a scalar [single row, single value] query
How can I pass attribute value from iframe to parent? I.e. iframe (frame1) has
So how can I pass a value from one form to another? For example:
I have a view with a grid that contains items added to a workstation.
I have a grid, when i click on the edit button it goes to
I have this logical problem regarding on how to pass value from one JFrame
I have a windows forms application that shows data in a grid view. The
I have a form with a grid and I want to pass info from
I have a view that I pass a viewmodel object to that contains an

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.