Home All Groups Group Topic Archive Search About

Access a BoundColumn's value in Update, other than .Cells()?

Author
5 Mar 2005 12:49 AM
awbacker
I am accepting a record update from a datagrid. In the update handler,
is there any way to get the value stored in the edited column w/o
e.Item.Cells(xx)....

I would like to be able to rearrange the columns in the DG as
necessary, or add new ones. Right now this forces me to recompile &
recode.

I find it difficult to believe that the DG would be written this way.
It seems to force me to use magic numbers to access columns, rather
than searching for a specified ID, etc. This way appears to be a
nightmare, so either there was a very good reason to make it difficulut
to get at, or it was just a big mistake.

Am I better off forgetting using BoundColumn and putting in
TemplateColumn? I can then search ever column and every control in
every column to find the one I expect, when update is pushed?

I have 4 columns I display, but only one that I allow editing of 1 ATM.


- Andrew Backer

Author
8 Mar 2005 8:21 PM
Andrew Backer
I've been told in other places that the only real way to acomplish this
is to use <TemplateColumn> and then do a search for the control i'm
interested in via eArgs.Item.FindContro("...").

I was hoping that there was some way to locate a bound column & it's
value by *any* other means.  Oh well :)

- Andrew