Is it possible to add the new row always on the top of the datagrid
I came across this solution
http://forums.infragistics.com/forums/p/44535/243209.aspx#243209
but the Row_Added is not getting triggered
Thanks. Didnt occur to me that i could add it this way
You're canceling the add in the RowAdding event, so RowAdded will never be raised.
Since you're doing the adding...just insert the object to the top of your collection, instead of at the end..
-SteveZ
Attached is the sample code
Table structure is as follows
USE [Sample]GO
/****** Object: Table [dbo].[DummyTable] Script Date: 05/31/2011 10:24:20 ******/SET ANSI_NULLS ONGO
SET QUOTED_IDENTIFIER ONGO
SET ANSI_PADDING ONGO
CREATE TABLE [dbo].[DummyTable]( [TID] [int] IDENTITY(1,1) NOT NULL, [Name] [varchar](50) NULL, [City] [varchar](50) NULL, [State] [varchar](50) NULL, [Age] [int] NULL, [Salary] [decimal](18, 0) NULL, [Saving] [decimal](18, 0) NULL) ON [PRIMARY]
GO
SET ANSI_PADDING OFFGO
Hi,
The RowAdded event should always get triggered when adding a row via the xamGrid. Do you have a sample that shows it not happening?