I like to stay in the hard-coded markup for ASP .Net and html. However, on a team I have no control of other developers flipping over to Visual Studio's 'Design Mode'. Versions of Visual Studio after 2003 improved to where flipping back and forth from 'Design Mode' to 'Text Mode' did not butcher the HTML markup. But for some reason Telerik ASP .Net controls still end up with weird formatting and inserting duplicate style tags on my RadGrid columns (for instance).
Is there anything that can be done about this? See this example.
The <ItemStyle HorizaontalAlign="Right" Width="85px"></ItemStyle> was not input by the developer, and it is a duplicate of settings already in the columns. It appeared after the developer made some other settings on the grid withing VS 'Design Mode'.
I understand 'Design Mode' isn't best, but it should not insert new markup and reformat the other markup so badly.
Is there anything that can be done about this? See this example.
<
Columns
>
<
telerik:GridBoundColumn
DataField
=
"Patient.DisplayId"
DataType
=
"System.String"
HeaderText
=
"Patient ID"
SortExpression
=
"Patient.DisplayId"
/>
<
telerik:GridBoundColumn
DataField
=
"Patient.FullName"
DataType
=
"System.String"
HeaderText
=
"Name"
SortExpression
=
"Patient.FullName"
/>
<
telerik:GridDateTimeColumn
DataField
=
"Patient.Dob"
DataType
=
"System.DateTime"
HeaderText
=
"Date of Birth"
SortExpression
=
"Patient.Dob"
ItemStyle-Width
=
"85px"
DataFormatString
=
"{0:MM/dd/yyyy}"
>
<
ItemStyle
Width
=
"85px"
></
ItemStyle
>
</
telerik:GridDateTimeColumn
>
<
telerik:GridNumericColumn
DataField
=
"Age"
DataType
=
"System.Int32"
HeaderText
=
"Age"
SortExpression
=
"Age"
ItemStyle-HorizontalAlign
=
"Right"
ItemStyle-Width
=
"50px"
>
<
ItemStyle
HorizontalAlign
=
"Right"
Width
=
"50px"
></
ItemStyle
>
</
telerik:GridNumericColumn
>
<
telerik:GridNumericColumn
DataField
=
"Count"
DataType
=
"System.Int32"
HeaderText
=
"Claims"
SortExpression
=
"Count"
ItemStyle-HorizontalAlign
=
"Right"
ItemStyle-Width
=
"50px"
>
<
ItemStyle
HorizontalAlign
=
"Right"
Width
=
"50px"
></
ItemStyle
>
</
telerik:GridNumericColumn
>
<
telerik:GridNumericColumn
DataField
=
"AmountPaid"
DataType
=
"System.Decimal"
HeaderText
=
"Amount Paid"
SortExpression
=
"AmountPaid"
ItemStyle-HorizontalAlign
=
"Right"
DataFormatString
=
"{0:c}"
ItemStyle-Width
=
"85px"
>
<
ItemStyle
HorizontalAlign
=
"Right"
Width
=
"85px"
></
ItemStyle
>
</
telerik:GridNumericColumn
>
</
Columns
>
The <ItemStyle HorizaontalAlign="Right" Width="85px"></ItemStyle> was not input by the developer, and it is a duplicate of settings already in the columns. It appeared after the developer made some other settings on the grid withing VS 'Design Mode'.
I understand 'Design Mode' isn't best, but it should not insert new markup and reformat the other markup so badly.