or
GridViewRelation selfRelaction =
new
GridViewRelation(
this
.radGridView1.MasterTemplate,
this
.radGridView1.MasterTemplate);
selfRelaction.ParentColumnNames.Add(
"column1"
);
selfRelaction.ChildColumnNames.Add(
"column2"
);
this
.radGridView1.Relations.Add(selfRelaction);
this
.radGridView1.Columns[
"column1"
].IsVisible =
false
;
this
.radGridView1.Columns[
"column2"
].IsVisible =
false
;
this
.radGridView1.Rows.Add(1,
null
,
"1"
,
"1"
,
"1"
,
"1"
);
this
.radGridView1.Rows.Add(2, 1,
"1"
,
"1"
,
"1"
,
"1"
);
this
.radGridView1.Rows.Add(3,
null
,
"1"
,
"1"
,
"1"
,
"1"
);
this
.radGridView1.Rows.Add(4, 3,
"1"
,
"1"
,
"1"
,
"1"
);
this
.radGridView1.Rows.Add(5,
null
,
"1"
,
"1"
,
"1"
,
"1"
);
//error : radGridView1.Rows.Count is "0"!
this
.radGridView1.Rows[0].IsExpanded =
true
;
this
.radGridView1.Rows[2].IsExpanded =
true
;
radGridView1.Rows.Count is "0"!
Help me! Both Q2 and Q3!
radDock.AutoHideWindow(toolWindow);
How can I disable hot tracking from column header elements?
Regards
I have a win form with a DataGridView and two edit fields and a binding navigator.The DataGridView and the edit fields are bound to a database table.
If i press the „Add“ button in the binding navigator, the DataGridView scrolls down to the bottom, adds an empty line at the bottom and the two edit fields are cleared. After entering data in the edit fields, and selecting any other items in the DataGridView, the values from the edit fields are shown in the new line at the bottom of the grid.
Now I have replaced the DataGridView with the RadGridView 2010 Q3.
If I press the „Add“ button in the binding navigator, the RadGridView scrolls down (but not to the very bottom), adds an empty line at the bottom, however it does not scroll to this new line. So it’s invisible until the user scrolls the list to the end. The two edit fields still have the content of the last selected item. They are not cleared. I can overwrite in the two edit fields the existing values with some new values. The new values are now in the dataset but the RadDataView is not updated with the new values. At the bottom in the grid, there is still the new empty line. If I click on the empty line, the correct values are shown in the edit fields.
dsRittenTemp.Clear()
dsGoederenTemp.Clear()
'
cmdRittenTemp =
New
Odbc.OdbcCommand(
"Select * FROM ritten_temp WHERE ritnummer = '"
& RitNummer &
"'"
, cn)
adpRittenTemp =
New
Odbc.OdbcDataAdapter(cmdRittenTemp)
adpRittenTemp.Fill(dsRittenTemp,
"ritten_temp"
)
'
cmdGoederenTemp =
New
Odbc.OdbcCommand(
"Select * FROM goederen_temp"
, cn)
adpGoederenTemp =
New
Odbc.OdbcDataAdapter(cmdGoederenTemp)
adpGoederenTemp.Fill(dsGoederenTemp,
"goederen_temp"
)
' Me.RadGridViewOverView.MasterTemplate.Templates.Clear()
RadGridViewOverView.DataSource = dsRittenTemp
RadGridViewOverView.DataMember =
"ritten_temp"
Dim
template
As
New
GridViewTemplate()
template.DataSource = dsGoederenTemp
template.DataMember =
"goederen_temp"
RadGridViewOverView.MasterTemplate.Templates.Add(template)
Dim
relation
As
New
GridViewRelation(RadGridViewOverView.MasterTemplate)
relation.ChildTemplate = template
relation.RelationName =
"goederenticket"
relation.ParentColumnNames.Add(
"goederenticket"
)
relation.ChildColumnNames.Add(
"goederenticket"
)
RadGridViewOverView.Relations.Add(relation)
RadGridViewOverView.AllowEditRow =
False
RadGridViewOverView.MasterTemplate.Templates(0).AllowEditRow =
False