Hello,
Could someone help on the following.
I have a WebDataGrid populated with the data from a database. All I need to achieve is being able
to pass a value of a cell (let's say the first one) on clicking or double clicking on a row in the grid.
Thanks in advance,
Kind regards,
Shurik.
p.s. @ Infrastics team: I've been an occasional user of NetAdvantage controls for several years already (mostly Winforms). I can't call myself an expert in the field but still I can't stop having a feeling that with each new release it gets more and more difficult to get you started.
The documentation is either not complete or spread over the different places. If you ask a question in one of the forums, most of the time you get answer, but I do miss a good set of 'Samples'/FAQs stored in one place... it takes you ages to achieve something relatively simple.
Again it might be not an issue for an experienced programmer but I think it's also worth thinking about targeting other groups.
Just my two cents of course...
Pardon for bumping the topic
With UltraWebGrid it took 2 lines of code to get a value of cell in the row
--------------------------------------------------------------
protected void ugrdMetersList_DblClick(object sender, ClickEventArgs e) { ... int row_index = 0;
string meter_num=System.String.Empty;
row_index = int.Parse(e.Cell.Row.Index.ToString()); // this works meter_num = this.ugrdMetersList.Rows[row_index].Cells[0].Text.ToString(); ..... }-------------------------------------------------------------
Is something like this possible in WebDataGrid? Is JavaScript plumbing the only solution?
Thank you.
Hello Shurik,
Definitely the same functionality exists in the WDG. The Cells collection however is called Items here. Everything else should be pretty close to UWG.
Hi Alex,
Thanks for your reply. I had a look in the on-line documentation:
http://help.infragistics.com/NetAdvantage/ASPNET/2011.1/CLR4.0/
--> Developer's Guide --> Controls -->WebDataGrid --> Getting Started with WebDataGrid/ Using WebDataGrid... but at a first glance could not find anything directly related to my question.
I see that WebDataGrid has 'Click' and 'DoubleClick' ClientEvents, but what next?
Just to avoid misunderstanding I'm not asking to write the code for me, but rather point out where I could find concrete information on the steps to be taken to achieve this.
Assume my entry-level knowledge of JavaScript/ Ajax functionalities
Thanks a lot,
Regards,
When handling the client side events for Click and DoubleClick you can get the cell's value within the eventArgs parameter: "eventArgs.get_item().get_row().get_cell(0).get_value()".
This will return the value of the first cell of the row that was clicked on.
Let me know if you have any questions with this matter. Thank you.
The desire is not for a ClientEvent it's for a code behind event. The definition was a C# function to handle a _DblClick event on the server side.
Please advise how to do this. I too find using the Infragistics site as a resource, cumbersome and difficult at best.
Did you ever find an answer to this on the server side? I have a number of old Utra Web Grids that are programed to do things when an individual cell is clicked but its all server side.
So I was curious if you found a way to do this. This company left everyone hanging who used the old controls, it is ridiculous and is the reason many of us will never be a customer again.