|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Serious problem with TableLayoutPanel on localizable formsThe same problem is described in post from James Minns (see bellow) with the complete steps to reproduce. Is there any workaround? *************** I have come across a bug which causes big problems with the TableLayoutPanel on non American Windows. The layout of the rows and columns is completely garbled. To reproduce the problem: In the control panel, choose regional setting for Italy, say (anywhere where the decimal separator is a comma) Create a TableLayoutPanel with three rows and make the height of each row 33.33% of the table. Save the form - it still runs ok Now set Localizable=True for the form. The damage is done. All the row heights are moved from the designer.vb code to the resx file, and because the Italian regional settings use the comma as a decimal separator, the resx file contains to following: Rows Styles="Percent,33,33333,Percent,33,33333,Percent,33,33333" The next time you load the form from disk in Visual Studio, the above line is parsed incorrectly - you get the following: Row 1: Size Type: Percent Value 33,00% Row 2: SizeType: 33333 Value <empty space> Row 3: SizeType: 33 Value <empty space> and your painstakingly formatted table is mangled. You've got to love that sizetype=3333, it should be absolute, percent or autosize! Workaround is to set control panel to USA until the resx is compiled, or abandon TableLayoutPanel for foreign language apps. Solution for Microsoft should be to store the Row Styles string using the correct list separator symbol (semicolon here, comma in USA) or not use regional settings at all when writing the resx file. Microsoft, are you reading? James |
|||||||||||||||||||||||