Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
55
WebDataGrid Navigate other page when dobleclick row
posted

How can I do the follow when user dobleclick a row:

  • Set a string value to a C# variable with a select row column
  • navigate to another webform

I really has not too much experience on webform my main programming platform its winform but I trying to solve this, I have the 19.1 version of Infragisttics Utlimate

Thanks in advance for your help

Alejandro Castrejon

Parents
No Data
Reply
  • 300
    Offline posted

    Hello Alejandro,

    Thank you for posting in our community.

    One way is to use EnteringEditMode event handler of a row. You can cancel the event so you don't enter edit mode and do a manual postback passing the cell's value:

    <script>
       function grid_RowEditing_EnteringEditMode(sender, eventArgs) {
    		eventArgs.set_cancel(true)
    		__doPostBack('Navigate', eventArgs.getCells()[4].get_value());
    	}
    </script>

    In the code-behind you can redirect to a page based on the cell's value:

    protected void Page_Load(object sender, EventArgs e)
    {
    	var page = Request["__EVENTARGUMENT"];
    	if (page != null) Response.Redirect(page + ".aspx");
    }

    I’ve attached a sample for your reference.

    3465.Sample.zip

Children
No Data