Home All Groups Group Topic Archive Search About

Adding variable default values to new record in datagrid

Author
28 Mar 2005 1:41 PM
Mike VaughanEdwards via .NET 247
I want to add contect-specific default field values when I create a new record in a data grid.   It will not always be the same value so I need to set it in code rather than in the database design but I can not find the right object/event that will let me do this?

Any suggestions?

TIA

Mike VE

--------------------------------
From: Mike VaughanEdwards

-----------------------
Posted by a user from .NET 247 (http://www.dotnet247.com/)

<Id>PoudvMdPj0iRkcfad5joWg==</Id>

Author
28 Mar 2005 5:28 PM
Andrew Conrad
Can the code to determine the value be expressed via standard datatable
expression columns?

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/
frlrfsystemdatadatacolumnclassexpressiontopic.asp

Andrew Conrad
Microsoft Corp
Author
29 Mar 2005 1:28 AM
Val Mazur (MVP)
Hi,

Since you add row not to the grid itself, but to the underlying DataTable,
try to catch RowChanged event for this table. This event fires in a case if
you add, change or delete row
--
Val Mazur
Microsoft MVP

http://xport.mvps.org



"Mike VaughanEdwards via .NET 247" <anonym***@dotnet247.com> wrote in
message news:eb$nfv5MFHA.2136@TK2MSFTNGP14.phx.gbl...
I want to add contect-specific default field values when I create a new
record in a data grid.   It will not always be the same value so I need to
set it in code rather than in the database design but I can not find the
right object/event that will let me do this?

Any suggestions?

TIA

Mike VE

--------------------------------
From: Mike VaughanEdwards

-----------------------
Posted by a user from .NET 247 (http://www.dotnet247.com/)

<Id>PoudvMdPj0iRkcfad5joWg==</Id>

AddThis Social Bookmark Button