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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T07:17:13+00:00 2026-06-16T07:17:13+00:00

I have 2 pages, an ASPxGridview & a button in the first page, and

  • 0

I have 2 pages, an ASPxGridview & a button in the first page, and a formview in the second page, the columns of the gridview are

ID
Name

I made the selection so that only a single row can be selected. When the user selects a row, then clicks the button, I want the ID of that row to be passed as querystring to the other page and use it in the where clause of the sqldatasource connected to the formsview.
how do i do this?

  • 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-16T07:17:14+00:00Added an answer on June 16, 2026 at 7:17 am

    Please follow the below steps for your requirement : (This is feasible approach, if you feel good to use it)

    1. Add Custom button to the asxpgridview

    Sample code :

    <dx:GridViewCommandColumn VisibleIndex="0" ButtonType="Image" Width="6%" Caption="Action"
        CellStyle-HorizontalAlign="Center" CellStyle-VerticalAlign="Top">
    <CustomButtons>
                <dx:GridViewCommandColumnCustomButton  ID="Select" Text="Select">
                        <Image Url="~/images/Select.png" ToolTip="Redirect ">
                                        </Image>                                                                               </dx:GridViewCommandColumnCustomButton>                                              
            </CustomButtons>
    

    2 Define custombutton click client side of the aspxgridview

    Sample Code:

    <ClientSideEvents CustomButtonClick="function(s, e) { OnCustomButtonClick(s, e); }" />
    

    3.In javascript use following to pass id to another page

    Sample Code :

    function OnCustomButtonClick(s, e) {
                switch (e.buttonID) {           
                    case "Select":
                        var Url = "NewPageURL.aspx?ID=" + s.GetRowKey(e.visibleIndex) + "";                 
                        window.open(Url, '', '');
                        break
                }
    
            } 
    

    4.Dont Forget TO Specify ID as your keyfieldname in aspxgridview definition.

    If any questions, please feel free to post here.

    Thanks 🙂

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

Sidebar

Related Questions

I have pages like index.php?key=toplist&list=magic So if om on that page for example, i
I have pages like this: page.php?id=1&name=whatever How could I transform this into... page/1/whatever
I have 2 pages that I want to show as instructions the first time
I have multiple pages branching of a title page, and when a back button
I have a page using ASPxGridView and to fill the GridView I use a
I have an ASPxGridView on my page which has a few columns of data.
If I have pages having server-side code in code-behind, then I know that the
I have two pages, one that edits user information, and one that edits information
I have web pages that are endless pages -- i.e. if the user goes
I have several pages to do with several table on each page. I've got

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.