Hi,
I have a radform with a gridview control. The "Localizable" property in the RadForm is true and there are only two columns in the gridview. In desgin time, I input the column header text for each column in grid. Then, I change the "Language" in the form and input the Column Header Text in other language.
However, after I switch back language to original, all the column header text I input before were missing.
Then, I checked the resx files for those two language and found that the "GridViewTextBoxColumn" in those files are different.
The resx file in original language (RadForm1.resx):
The resx file in other language (RadForm1.zh-Hant.resx):
Then, I switch the form language back to original language and find that in "RadForm1.zh-Hant.resx" file, the data name for grid column had changed to "GridViewTextBoxColumn3" instead of "GridViewTextBoxColumn1". So, the column header text can't display in original language.
I would like to know how can I fix it?
Thanks!
I have a radform with a gridview control. The "Localizable" property in the RadForm is true and there are only two columns in the gridview. In desgin time, I input the column header text for each column in grid. Then, I change the "Language" in the form and input the Column Header Text in other language.
However, after I switch back language to original, all the column header text I input before were missing.
Then, I checked the resx files for those two language and found that the "GridViewTextBoxColumn" in those files are different.
The resx file in original language (RadForm1.resx):
<
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
>
The resx file in other language (RadForm1.zh-Hant.resx):
<
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
>
Then, I switch the form language back to original language and find that in "RadForm1.zh-Hant.resx" file, the data name for grid column had changed to "GridViewTextBoxColumn3" instead of "GridViewTextBoxColumn1". So, the column header text can't display in original language.
<
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
>
I would like to know how can I fix it?
Thanks!