Essential Grouping ASP.NET
Double click evevnt in Grid grouping control
January 5, 2012 04:11 AM by Yogeshwaran[Syncfusion]
kallyani
Double click evevnt in Grid grouping control
July 14, 2008 06:50 AM
Hi,

I want to use the values of current record on which user double clicks. Please let me know what code i should write for the same . we are using syncfusion 6.3.0.6.

Thanks,
Kallyani

Rajarajeswari
[Syncfusion]
Double click evevnt in Grid grouping control
July 17, 2008 01:17 AM
Hi Kallyani,

Thanks for using Syncfusion products.

Double clicking on the records will leads to Edit mode in GridGroupingControl.But your requirement can be achieved with Single click through client side event called "ClientSideOnRecordClick".

Please refer the below code snippet which illustartes this:

function select(gridObj)
{
document.getElementById('TextBox1').innerText = gridObj.Row.GetValue('id');
}


Please refer the sample from the below link which illustartes this:

http://www.syncfusion.com/support/user/uploads/RecordValue_e503661f.zip

Please let me know if you have any other concerns.

Regards,
Raji

kallyani
Double click evevnt in Grid grouping control
August 1, 2008 04:08 AM
i want to use doubleclick functionality on ggc cell to bind data from clicked ggc cell to textbox. lemme know the server side code for the same.

Rajarajeswari
[Syncfusion]
Double click evevnt in Grid grouping control
August 6, 2008 01:17 PM
Hi Kallyani,

Thanks for using Syncfusion products.

On server side we are having “SelectedRecordsChanged” event, which will get raised for a record click. Please refer the below code snippet which is used to get the selected record through the “SelectedRecordsChanged” event:


protected void GridGroupingControl1_RecordsChanged(object sender, Syncfusion.Grouping.SelectedRecordsChangedEventArgs e)
{

Record r = this.GridGroupingControl1.Table.CurrentRecord;
if(r != null)
this.TextBox1.Text = r.GetValue("id").ToString();

if (ViewState["currentrecord"] == null)
{
ViewState["currentrecord"] = r.GetValue("id").ToString();
}
else if (r != null && r.IsCurrent)
{

if (ViewState["currentrecord"].ToString() != r.GetValue("id").ToString())
{
Record currentrec = r;
this.TextBox1.Text = currentrec.GetValue("id").ToString();
}
}

}

As I mentioned in my previous post, doubleclick of a record or cell leads to Editmode. The above code works for a single click.

Please refer the sample from the below link, which illustrates the above:

http://www.syncfusion.com/support/user/uploads/Sample_6821c861.zip

Please try the above and let us know if this helps you out.

Regards,
Raji


Deepika Jain
Double click evevnt in Grid grouping control
December 29, 2011 11:25 AM
Please post the sample code once again as the link that you posted doesn't seem to be working. I want to show an alert on double click og any of th erow in grid data control and this alert should show the values of the different columns in the clicked row. for example: my row contains employee name, id and their marks so on double click of this row, I want to get the individual values of this in some variables.

Yogeshwaran
[Syncfusion]
Double click evevnt in Grid grouping control
January 5, 2012 04:11 AM
Hi Deepika,

Thanks for using Syncfusion products.

Your requirement to get record value of currently double clicked row can be achieved by using client side event “ClientSideOnRowDoubleClick” .please refer the following code snippet.
[Jquery]

function Select(Gridobj) {

Temp = {};
$.each(Gridobj.Row.gridTable.visibleColumns, function (index, value) {
//index 0 is indent row . to avoid this we have to check condition
if(index !=0)
Temp[index] = Gridobj.Row.GetValue(value.name);
});

}



For your convenience, we have created the sample and the same can be downloaded from the below link.

ColumnWidth-GridWeb-136404553.zip

Please let us know if you have any concerns.

Regards,
Yogesh R

::adCenter::