It can be reproduced easily. First, I create a simple form with a RadGridView. The Form1.Designer.cs file is:
namespace
Test1
{
partial
class
Form1
{
/// <summary>
/// Required designer variable.
/// </summary>
private
System.ComponentModel.IContainer components =
null
;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected
override
void
Dispose(
bool
disposing)
{
if
(disposing && (components !=
null
))
{
components.Dispose();
}
base
.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private
void
InitializeComponent()
{
this
.radGridView1 =
new
Telerik.WinControls.UI.RadGridView();
((System.ComponentModel.ISupportInitialize)(
this
.radGridView1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(
this
.radGridView1.MasterTemplate)).BeginInit();
this
.SuspendLayout();
//
// radGridView1
//
this
.radGridView1.Dock = System.Windows.Forms.DockStyle.Fill;
this
.radGridView1.Location =
new
System.Drawing.Point(0, 0);
this
.radGridView1.Name =
"radGridView1"
;
this
.radGridView1.Size =
new
System.Drawing.Size(284, 264);
this
.radGridView1.TabIndex = 0;
this
.radGridView1.Text =
"radGridView1"
;
//
// Form1
//
this
.AutoScaleDimensions =
new
System.Drawing.SizeF(6F, 13F);
this
.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this
.ClientSize =
new
System.Drawing.Size(284, 264);
this
.Controls.Add(
this
.radGridView1);
this
.Name =
"Form1"
;
this
.Text =
"Form1"
;
((System.ComponentModel.ISupportInitialize)(
this
.radGridView1.MasterTemplate)).EndInit();
((System.ComponentModel.ISupportInitialize)(
this
.radGridView1)).EndInit();
this
.ResumeLayout(
false
);
}
#endregion
private
Telerik.WinControls.UI.RadGridView radGridView1;
}
}
Then I open the Designer View and click "Open Property Builder" for a grid. The Property Builder window blinks quickly and the following message box is shown:
---------------------------
Properties Window
---------------------------
Must specify valid information for parsing in the string.
---------------------------
OK
---------------------------
The Form1.Designer.cs file becomes the following:
namespace
Test1
{
partial
class
Form1
{
/// <summary>
/// Required designer variable.
/// </summary>
private
System.ComponentModel.IContainer components =
null
;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected
override
void
Dispose(
bool
disposing)
{
if
(disposing && (components !=
null
))
{
components.Dispose();
}
base
.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private
void
InitializeComponent()
{
this
.MasterTemplate =
new
Telerik.WinControls.UI.RadGridView();
((System.ComponentModel.ISupportInitialize)(
this
.MasterTemplate)).BeginInit();
((System.ComponentModel.ISupportInitialize)(
this
.MasterTemplate.MasterTemplate)).BeginInit();
this
.SuspendLayout();
//
// MasterTemplate
//
this
.MasterTemplate.Dock = System.Windows.Forms.DockStyle.Fill;
this
.MasterTemplate.Location =
new
System.Drawing.Point(0, 0);
this
.MasterTemplate.Name =
"MasterTemplate"
;
this
.MasterTemplate.Size =
new
System.Drawing.Size(284, 264);
this
.MasterTemplate.TabIndex = 0;
this
.MasterTemplate.Text =
"radGridView1"
;
//
// Form1
//
this
.AutoScaleDimensions =
new
System.Drawing.SizeF(6F, 13F);
this
.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this
.ClientSize =
new
System.Drawing.Size(284, 264);
this
.Controls.Add(
this
.radGridView1);
this
.Name =
"Form1"
;
this
.Text =
"Form1"
;
((System.ComponentModel.ISupportInitialize)(
this
.MasterTemplate.MasterTemplate)).EndInit();
((System.ComponentModel.ISupportInitialize)(
this
.MasterTemplate)).EndInit();
this
.ResumeLayout(
false
);
}
#endregion
private
Telerik.WinControls.UI.RadGridView radGridView1;
private
Telerik.WinControls.UI.RadGridView MasterTemplate;
}
}
I tried to uninstall the RadControls at all and install them from scratch. This did not help.
So, could you please help me with a work around this problem? I use a lot of grids in ny project, so, it would be a pity to miss the Property Builder feature.
Thank you.
<
xsd:schema
id
=
"root"
xmlns
=
""
xmlns:xsd
=
"http://www.w3.org/2001/XMLSchema"
xmlns:msdata
=
"urn:schemas-microsoft-com:xml-msdata"
>
<
xsd:import
namespace
=
"http://www.w3.org/XML/1998/namespace"
/>
<
xsd:element
name
=
"root"
msdata:IsDataSet
=
"true"
>
<
xsd:complexType
>
<
xsd:choice
maxOccurs
=
"unbounded"
>
<
xsd:element
name
=
"metadata"
>
<
xsd:complexType
>
<
xsd:sequence
>
<
xsd:element
name
=
"value"
type
=
"xsd:string"
minOccurs
=
"0"
/>
</
xsd:sequence
>
<
xsd:attribute
name
=
"name"
use
=
"required"
type
=
"xsd:string"
/>
<
xsd:attribute
name
=
"type"
type
=
"xsd:string"
/>
<
xsd:attribute
name
=
"mimetype"
type
=
"xsd:string"
/>
<
xsd:attribute
ref
=
"xml:space"
/>
</
xsd:complexType
>
</
xsd:element
>
<
xsd:element
name
=
"assembly"
>
<
xsd:complexType
>
<
xsd:attribute
name
=
"alias"
type
=
"xsd:string"
/>
<
xsd:attribute
name
=
"name"
type
=
"xsd:string"
/>
</
xsd:complexType
>
</
xsd:element
>
<
xsd:element
name
=
"data"
>
<
xsd:complexType
>
<
xsd:sequence
>
<
xsd:element
name
=
"value"
type
=
"xsd:string"
minOccurs
=
"0"
msdata:Ordinal
=
"1"
/>
<
xsd:element
name
=
"comment"
type
=
"xsd:string"
minOccurs
=
"0"
msdata:Ordinal
=
"2"
/>
</
xsd:sequence
>
<
xsd:attribute
name
=
"name"
type
=
"xsd:string"
use
=
"required"
msdata:Ordinal
=
"1"
/>
<
xsd:attribute
name
=
"type"
type
=
"xsd:string"
msdata:Ordinal
=
"3"
/>
<
xsd:attribute
name
=
"mimetype"
type
=
"xsd:string"
msdata:Ordinal
=
"4"
/>
<
xsd:attribute
ref
=
"xml:space"
/>
</
xsd:complexType
>
</
xsd:element
>
<
xsd:element
name
=
"resheader"
>
<
xsd:complexType
>
<
xsd:sequence
>
<
xsd:element
name
=
"value"
type
=
"xsd:string"
minOccurs
=
"0"
msdata:Ordinal
=
"1"
/>
</
xsd:sequence
>
<
xsd:attribute
name
=
"name"
type
=
"xsd:string"
use
=
"required"
/>
</
xsd:complexType
>
</
xsd:element
>
</
xsd:choice
>
</
xsd:complexType
>
</
xsd:element
>
</
xsd:schema
>
<
resheader
name
=
"resmimetype"
>
<
value
>text/microsoft-resx</
value
>
</
resheader
>
<
resheader
name
=
"version"
>
<
value
>2.0</
value
>
</
resheader
>
<
resheader
name
=
"reader"
>
<
value
>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</
value
>
</
resheader
>
<
resheader
name
=
"writer"
>
<
value
>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</
value
>
</
resheader
>
<
assembly
alias
=
"System.Drawing"
name
=
"System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
/>
<
data
name
=
"RadGridView1.Location"
type
=
"System.Drawing.Point, System.Drawing"
>
<
value
>0, 0</
value
>
</
data
>
<
data
name
=
"GridViewTextBoxColumn1.HeaderText"
xml:space
=
"preserve"
>
<
value
>column 1 in default</
value
>
</
data
>
<
data
name
=
"GridViewTextBoxColumn2.HeaderText"
xml:space
=
"preserve"
>
<
value
>column 2 in default</
value
>
</
data
>
<
data
name
=
"RadGridView1.Size"
type
=
"System.Drawing.Size, System.Drawing"
>
<
value
>240, 150</
value
>
</
data
>
<
assembly
alias
=
"mscorlib"
name
=
"mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"
/>
<
data
name
=
"RadGridView1.TabIndex"
type
=
"System.Int32, mscorlib"
>
<
value
>0</
value
>
</
data
>
<
data
name
=
"RadGridView1.Text"
xml:space
=
"preserve"
>
<
value
>RadGridView1</
value
>
</
data
>
<
data
name=">>RadGridView1.Name" xml:space="preserve">
<
value
>RadGridView1</
value
>
</
data
>
<
data
name=">>RadGridView1.Type" xml:space="preserve">
<
value
>Telerik.WinControls.UI.RadGridView, Telerik.WinControls.GridView, Version=2011.1.11.419, Culture=neutral, PublicKeyToken=5bb2a467cbec794e</
value
>
</
data
>
<
data
name=">>RadGridView1.Parent" xml:space="preserve">
<
value
>$this</
value
>
</
data
>
<
data
name=">>RadGridView1.ZOrder" xml:space="preserve">
<
value
>0</
value
>
</
data
>
<
metadata
name
=
"$this.Localizable"
type
=
"System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"
>
<
value
>True</
value
>
</
metadata
>
<
data
name
=
"$this.AutoScaleDimensions"
type
=
"System.Drawing.SizeF, System.Drawing"
>
<
value
>6, 13</
value
>
</
data
>
<
data
name
=
"$this.ClientSize"
type
=
"System.Drawing.Size, System.Drawing"
>
<
value
>308, 292</
value
>
</
data
>
<
data
name
=
"$this.Text"
xml:space
=
"preserve"
>
<
value
>RadForm1</
value
>
</
data
>
<
data
name=">>$this.Name" xml:space="preserve">
<
value
>RadForm1</
value
>
</
data
>
<
data
name=">>$this.Type" xml:space="preserve">
<
value
>Telerik.WinControls.UI.RadForm, Telerik.WinControls.UI, Version=2011.1.11.419, Culture=neutral, PublicKeyToken=5bb2a467cbec794e</
value
>
</
data
>
</
root
>
<
xsd:schema
id
=
"root"
xmlns
=
""
xmlns:xsd
=
"http://www.w3.org/2001/XMLSchema"
xmlns:msdata
=
"urn:schemas-microsoft-com:xml-msdata"
>
<
xsd:import
namespace
=
"http://www.w3.org/XML/1998/namespace"
/>
<
xsd:element
name
=
"root"
msdata:IsDataSet
=
"true"
>
<
xsd:complexType
>
<
xsd:choice
maxOccurs
=
"unbounded"
>
<
xsd:element
name
=
"metadata"
>
<
xsd:complexType
>
<
xsd:sequence
>
<
xsd:element
name
=
"value"
type
=
"xsd:string"
minOccurs
=
"0"
/>
</
xsd:sequence
>
<
xsd:attribute
name
=
"name"
use
=
"required"
type
=
"xsd:string"
/>
<
xsd:attribute
name
=
"type"
type
=
"xsd:string"
/>
<
xsd:attribute
name
=
"mimetype"
type
=
"xsd:string"
/>
<
xsd:attribute
ref
=
"xml:space"
/>
</
xsd:complexType
>
</
xsd:element
>
<
xsd:element
name
=
"assembly"
>
<
xsd:complexType
>
<
xsd:attribute
name
=
"alias"
type
=
"xsd:string"
/>
<
xsd:attribute
name
=
"name"
type
=
"xsd:string"
/>
</
xsd:complexType
>
</
xsd:element
>
<
xsd:element
name
=
"data"
>
<
xsd:complexType
>
<
xsd:sequence
>
<
xsd:element
name
=
"value"
type
=
"xsd:string"
minOccurs
=
"0"
msdata:Ordinal
=
"1"
/>
<
xsd:element
name
=
"comment"
type
=
"xsd:string"
minOccurs
=
"0"
msdata:Ordinal
=
"2"
/>
</
xsd:sequence
>
<
xsd:attribute
name
=
"name"
type
=
"xsd:string"
use
=
"required"
msdata:Ordinal
=
"1"
/>
<
xsd:attribute
name
=
"type"
type
=
"xsd:string"
msdata:Ordinal
=
"3"
/>
<
xsd:attribute
name
=
"mimetype"
type
=
"xsd:string"
msdata:Ordinal
=
"4"
/>
<
xsd:attribute
ref
=
"xml:space"
/>
</
xsd:complexType
>
</
xsd:element
>
<
xsd:element
name
=
"resheader"
>
<
xsd:complexType
>
<
xsd:sequence
>
<
xsd:element
name
=
"value"
type
=
"xsd:string"
minOccurs
=
"0"
msdata:Ordinal
=
"1"
/>
</
xsd:sequence
>
<
xsd:attribute
name
=
"name"
type
=
"xsd:string"
use
=
"required"
/>
</
xsd:complexType
>
</
xsd:element
>
</
xsd:choice
>
</
xsd:complexType
>
</
xsd:element
>
</
xsd:schema
>
<
resheader
name
=
"resmimetype"
>
<
value
>text/microsoft-resx</
value
>
</
resheader
>
<
resheader
name
=
"version"
>
<
value
>2.0</
value
>
</
resheader
>
<
resheader
name
=
"reader"
>
<
value
>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</
value
>
</
resheader
>
<
resheader
name
=
"writer"
>
<
value
>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</
value
>
</
resheader
>
<
data
name
=
"GridViewTextBoxColumn1.HeaderText"
xml:space
=
"preserve"
>
<
value
>column 1 in other language</
value
>
</
data
>
<
data
name
=
"GridViewTextBoxColumn2.HeaderText"
xml:space
=
"preserve"
>
<
value
>column 2 in other language</
value
>
</
data
>
</
root
>
<
xsd:schema
id
=
"root"
xmlns
=
""
xmlns:xsd
=
"http://www.w3.org/2001/XMLSchema"
xmlns:msdata
=
"urn:schemas-microsoft-com:xml-msdata"
>
<
xsd:import
namespace
=
"http://www.w3.org/XML/1998/namespace"
/>
<
xsd:element
name
=
"root"
msdata:IsDataSet
=
"true"
>
<
xsd:complexType
>
<
xsd:choice
maxOccurs
=
"unbounded"
>
<
xsd:element
name
=
"metadata"
>
<
xsd:complexType
>
<
xsd:sequence
>
<
xsd:element
name
=
"value"
type
=
"xsd:string"
minOccurs
=
"0"
/>
</
xsd:sequence
>
<
xsd:attribute
name
=
"name"
use
=
"required"
type
=
"xsd:string"
/>
<
xsd:attribute
name
=
"type"
type
=
"xsd:string"
/>
<
xsd:attribute
name
=
"mimetype"
type
=
"xsd:string"
/>
<
xsd:attribute
ref
=
"xml:space"
/>
</
xsd:complexType
>
</
xsd:element
>
<
xsd:element
name
=
"assembly"
>
<
xsd:complexType
>
<
xsd:attribute
name
=
"alias"
type
=
"xsd:string"
/>
<
xsd:attribute
name
=
"name"
type
=
"xsd:string"
/>
</
xsd:complexType
>
</
xsd:element
>
<
xsd:element
name
=
"data"
>
<
xsd:complexType
>
<
xsd:sequence
>
<
xsd:element
name
=
"value"
type
=
"xsd:string"
minOccurs
=
"0"
msdata:Ordinal
=
"1"
/>
<
xsd:element
name
=
"comment"
type
=
"xsd:string"
minOccurs
=
"0"
msdata:Ordinal
=
"2"
/>
</
xsd:sequence
>
<
xsd:attribute
name
=
"name"
type
=
"xsd:string"
use
=
"required"
msdata:Ordinal
=
"1"
/>
<
xsd:attribute
name
=
"type"
type
=
"xsd:string"
msdata:Ordinal
=
"3"
/>
<
xsd:attribute
name
=
"mimetype"
type
=
"xsd:string"
msdata:Ordinal
=
"4"
/>
<
xsd:attribute
ref
=
"xml:space"
/>
</
xsd:complexType
>
</
xsd:element
>
<
xsd:element
name
=
"resheader"
>
<
xsd:complexType
>
<
xsd:sequence
>
<
xsd:element
name
=
"value"
type
=
"xsd:string"
minOccurs
=
"0"
msdata:Ordinal
=
"1"
/>
</
xsd:sequence
>
<
xsd:attribute
name
=
"name"
type
=
"xsd:string"
use
=
"required"
/>
</
xsd:complexType
>
</
xsd:element
>
</
xsd:choice
>
</
xsd:complexType
>
</
xsd:element
>
</
xsd:schema
>
<
resheader
name
=
"resmimetype"
>
<
value
>text/microsoft-resx</
value
>
</
resheader
>
<
resheader
name
=
"version"
>
<
value
>2.0</
value
>
</
resheader
>
<
resheader
name
=
"reader"
>
<
value
>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</
value
>
</
resheader
>
<
resheader
name
=
"writer"
>
<
value
>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</
value
>
</
resheader
>
<
data
name
=
"GridViewTextBoxColumn3.HeaderText"
xml:space
=
"preserve"
>
<
value
>column 1 in other language</
value
>
</
data
>
<
data
name
=
"GridViewTextBoxColumn4.HeaderText"
xml:space
=
"preserve"
>
<
value
>column 2 in other language</
value
>
</
data
>
</
root
>
void CreateUnboundHierarchy()
{
this.radGridView.MasterTemplate.Reset();
SetupMasterForUnbound();
GridViewTemplate ChildTemplate = SetupChildForUnbound();
this.radGridView.Templates.Add(ChildTemplate);
this.radGridView.CreateCell += new GridViewCreateCellEventHandler(radGridView_CreateCell);
//--
ChildTemplate.HierarchyDataProvider = new GridViewEventDataProvider(ChildTemplate);
//this.radGridView.RowSourceNeeded += new GridViewRowSourceNeededEventHandler(radGridView_RowSourceNeeded);
this.radGridView.UserAddingRow += new GridViewRowCancelEventHandler(radGridView_UserAddingRow);
LoadDataForUnbound();
}
void SetupMasterForUnbound()
{
this.radGridView.AllowAutoSizeColumns = true;
this.radGridView.MasterTemplate.AllowAddNewRow = false;
this.radGridView.MasterTemplate.AllowDeleteRow = false;
//-------------
//--
GridViewCheckBoxColumn chk1 = new GridViewCheckBoxColumn("SO");
chk1.HeaderText = "SO";
chk1.ReadOnly = true;
this.radGridView.MasterTemplate.Columns.Add(chk1);
//-------------
//--
GridViewTextBoxColumn textColumn1 = new GridViewTextBoxColumn("ChargeCode");
textColumn1.HeaderText = "ChargeCode";
textColumn1.ReadOnly = true;
this.radGridView.MasterTemplate.Columns.Add(textColumn1);
//--
GridViewTextBoxColumn textColumn2 = new GridViewTextBoxColumn("Description");
textColumn2.HeaderText = "Description";
textColumn2.ReadOnly = true;
this.radGridView.MasterTemplate.Columns.Add(textColumn2);
//--
GridViewDecimalColumn decimalColumn = new GridViewDecimalColumn("UnitCost");
decimalColumn.HeaderText = "UnitCost";
decimalColumn.FormatString = "{0:0.000}";
decimalColumn.ReadOnly = true;
this.radGridView.MasterTemplate.Columns.Add(decimalColumn);
//--
GridViewDecimalColumn decimalColumn1 = new GridViewDecimalColumn("Qty");
decimalColumn1.HeaderText = "Qty";
decimalColumn1.FormatString = "{0:0.000}";
decimalColumn1.ReadOnly = true;
this.radGridView.MasterTemplate.Columns.Add(decimalColumn1);
//--
GridViewDecimalColumn decimalColumn3 = new GridViewDecimalColumn("TotalCost");
decimalColumn3.HeaderText = "TotalCost";
decimalColumn3.FormatString = "{0:0.000}";
decimalColumn3.ReadOnly = true;
this.radGridView.MasterTemplate.Columns.Add(decimalColumn3);
//--
//--
GridViewCheckBoxColumn chk2 = new GridViewCheckBoxColumn("Charge");
chk2.HeaderText = "Charge";
chk2.ReadOnly = true;
this.radGridView.MasterTemplate.Columns.Add(chk2);
//--
GridViewCheckBoxColumn chk3 = new GridViewCheckBoxColumn("Checked");
chk3.HeaderText = "Checked";
chk3.ReadOnly = true;
this.radGridView.MasterTemplate.Columns.Add(chk3);
//--
this.radGridView.MasterTemplate.AutoSizeColumnsMode = GridViewAutoSizeColumnsMode.Fill;
//----------------------------
}
private GridViewTemplate SetupChildForUnbound()
{
GridViewTemplate template = new GridViewTemplate();
template.AllowAddNewRow = true;
template.AllowDeleteRow = false;
//---------------------------------------------------------------
//---------------------------------------------------------------
GridViewTextBoxColumn editButtonColumn = new GridViewTextBoxColumn();
editButtonColumn.Name = "Edit";
editButtonColumn.FieldName = "Edit";
editButtonColumn.ReadOnly = true;
editButtonColumn.HeaderText = "Edit";
editButtonColumn.Width = 100;
template.Columns.Add(editButtonColumn);
//-----------------------------------------------------------------
// template.Columns.Add(new GridViewCheckBoxColumn("SO"));
GridViewDecimalColumn Num = new GridViewDecimalColumn("Billable");
Num.HeaderText = "Billable";
Num.ReadOnly = true;
Num.IsVisible = false;
template.Columns.Add(Num);
//--
GridViewCheckBoxColumn chk1 = new GridViewCheckBoxColumn("SO");
chk1.HeaderText = "SO";
chk1.ReadOnly = true;
template.Columns.Add(chk1);
//--
GridViewTextBoxColumn textColumn1 = new GridViewTextBoxColumn("ChargeCode");
textColumn1.HeaderText = "ChargeCode";
textColumn1.ReadOnly = true;
template.Columns.Add(textColumn1);
//--
GridViewTextBoxColumn textColumn2 = new GridViewTextBoxColumn("Description");
textColumn2.HeaderText = "Description";
textColumn2.ReadOnly = true;
template.Columns.Add(textColumn2);
//--
GridViewTextBoxColumn textColumn3 = new GridViewTextBoxColumn("Barcode");
textColumn3.HeaderText = "Barcode";
textColumn3.ReadOnly = true;
template.Columns.Add(textColumn3);
//--
GridViewTextBoxColumn textColumn4 = new GridViewTextBoxColumn("Dept");
textColumn4.HeaderText = "Dept";
textColumn4.ReadOnly = true;
template.Columns.Add(textColumn4);
//--
GridViewDateTimeColumn Date1 = new GridViewDateTimeColumn("Date");
Date1.HeaderText = "Date";
Date1.ReadOnly = true;
Date1.FormatString = "{0:d}";
template.Columns.Add(Date1);
//--
GridViewTextBoxColumn textColumn5 = new GridViewTextBoxColumn("Site");
textColumn5.HeaderText = "Site";
textColumn5.ReadOnly = true;
template.Columns.Add(textColumn5);
//--
GridViewDecimalColumn decimalColumn1 = new GridViewDecimalColumn("Qty");
decimalColumn1.HeaderText = "Qty";
decimalColumn1.FormatString = "{0:0.000}";
decimalColumn1.ReadOnly = true;
template.Columns.Add(decimalColumn1);
//--
GridViewDecimalColumn decimalColumn = new GridViewDecimalColumn("UnitCost");
decimalColumn.HeaderText = "UnitCost";
decimalColumn.FormatString = "{0:0.000}";
decimalColumn.ReadOnly = true;
template.Columns.Add(decimalColumn);
//--
GridViewDecimalColumn decimalColumn3 = new GridViewDecimalColumn("TotalCost");
decimalColumn3.HeaderText = "TotalCost";
decimalColumn3.ReadOnly = true;
decimalColumn3.FormatString = "{0:0.000}";
template.Columns.Add(decimalColumn3);
//--
GridViewCheckBoxColumn chk2 = new GridViewCheckBoxColumn("Charge");
chk2.HeaderText = "Charge";
chk2.ReadOnly = true;
template.Columns.Add(chk2);
//--
GridViewCheckBoxColumn chk3 = new GridViewCheckBoxColumn("Checked");
chk3.HeaderText = "Checked";
chk3.ReadOnly = true;
template.Columns.Add(chk3);
//--
template.AutoSizeColumnsMode = GridViewAutoSizeColumnsMode.Fill;
return template;
}
void LoadDataForUnbound()
{
using (this.radGridView.DeferRefresh())
{
for (int i = 0; i < dts_DWBillDataSet.sps_BillableGrouped.Count; i++)
{
dts_DWBillDataSet.sps_BillableGroupedRow row = dts_DWBillDataSet.sps_BillableGrouped[i];
this.radGridView.MasterTemplate.Rows.Add(row.SO, row.ChargeCode, row.Description, row.UnitCost, row.Qty, row.TotalCost,row.Charge,row.Checked);
}
}
}