or
Private
Sub
gridIssues_DataBindingComplete(sender
As
Object
, e
As
Telerik.WinControls.UI.GridViewBindingCompleteEventArgs)
Handles
gridIssues.DataBindingComplete
CType
(gridIssues.Columns(
"balance"
), GridViewDecimalColumn).ThousandsSeparator =
True
End
Sub
Hi,
When I move by mistakes a node on the node over him, the application crash with the error bellow.
To reproduce this,
> Create a treeView with 2 nodes inside!
> Move the second node into the first one,
> Do it again (Move the second node that is already into the first one exactly as you did before)
I hope you can reproduce it and tell me how to avoid this problem.
Best regards, Fred
private
void
frmMain_Load(
object
sender, EventArgs e)
{
DataSet ds =
new
DataSet();
DataRelation relation;
string
connectionString =
"server=MYSQLSERVER;database=MyStore;uid=FakeUserID;pwd=FakePassword"
;
SqlConnection mySqlConnection =
new
SqlConnection(connectionString);
string
strCustomer_Query =
"Select * from Customer"
;
string
strPurchases_Query =
"Select * from Purchases"
;
try
{
SqlCommand sql_Customer =
new
SqlCommand(strCustomer_Query, mySqlConnection);
SqlDataAdapter da =
new
SqlDataAdapter(sql_Customer);
da.Fill(ds,
"Customer"
);
da.SelectCommand.CommandText = strPurchases_Query;
da.Fill(ds,
"Purchases"
);
// Add the relation. Maybe this is not needed because we use the RelationBindings of the RadTreeView
DataColumn parentCol = ds.Tables[
"Customer"
].Columns[
"ID"
];
DataColumn childCol = ds.Tables[
"Purchases"
].Columns[
"Customer_ID"
];
relation =
new
DataRelation(
"Customer_Purchases"
, parentCol, childCol);
ds.Relations.Add(relation);
treeView1.ShowLines =
true
;
treeView1.RelationBindings.Add(
new
RelationBinding(ds,
"CustomerName"
,
"Customer_ID"
,
"PurchaseID"
,
"ID"
));
treeView1.DataSource = ds;
treeView1.DisplayMember =
"CustomerName"
;
treeView1.ValueMember =
"ID"
;
treeView1.ParentMember =
"ID"
;
treeView1.ChildMember =
"PurchaseID"
;
treeView1.ExpandAll();
}