Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
235
TemplatedColumn cleaning
posted

Hi,

I have a problem with TemplatedColumn. I am having a tree control and ultrawebgrid. If user clicks on a tree element, the grid is dynamically loaded with TemplatedColumn inside. The code looks like this:

uwg_Grid.ResetRows()
uwg_Grid.ResetColumns()
uwg_Grid.Clear()
uwg_Grid.Columns.Add(New Infragistics.WebUI.UltraWebGrid.UltraGridColumn("ID", "ID", Infragistics.WebUI.UltraWebGrid.ColumnType.NotSet, ""), True)
Dim col As New Infragistics.WebUI.UltraWebGrid.TemplatedColumn
col.Key = "template"
col.HeaderText = "Column"
col.CellTemplate = New PropertyTemplate(str_AssemblyName, str_NameSpace)

uwg_Grid.Columns.Insert(uwg_Grid.Bands(0).Columns.Count, col)

Inside  PropertyTemplate class I am implementing InstantiateIn method where I am adding new TextBox to the cells. The problem is that if you enter something into any textbox in that TemplatedColumn, and click another tree element the above code will run which should clear the webgrid and recreate it from the scratch with empty values in cells, but somehow the value you have entered still exists. Do I need to perform some additional clearing of the TemplatedColumn ?

Thanks in advance

Bartek

 

Parents Reply Children
No Data