Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
Developer Community with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
1) Add label to view
2) Set Number of lines = 0 for this label in designer
3) Save storyboard
4) Open storyboard file as xml and find there description of added label. We can see that numberOfLines="0.0".
After some working with such a storyboard error message about custom components rendering will appear. In designer log there is exception
System.FormatException: Input string was not in a correct format.
at System.Number.StringToNumber (System.String str, System.Globalization.NumberStyles options, System.Number+NumberBuffer& number, System.Globalization.NumberFormatInfo info, System.Boolean parseDecimal) [0x0005f] in /Library/Frameworks/Xamarin.iOS.framework/Versions/10.99.8.25/src/mono/mcs/class/referencesource/mscorlib/system/number.cs:1077
at System.Number.ParseInt32 (System.String s, System.Globalization.NumberStyles style, System.Globalization.NumberFormatInfo info) [0x00015] in /Library/Frameworks/Xamarin.iOS.framework/Versions/10.99.8.25/src/mono/mcs/class/referencesource/mscorlib/system/number.cs:745
at System.Int32.Parse (System.String s, System.Globalization.NumberStyles style, System.IFormatProvider provider) [0x00006] in /Library/Frameworks/Xamarin.iOS.framework/Versions/10.99.8.25/src/mono/mcs/class/referencesource/mscorlib/system/int32.cs:145
at System.Convert.ToInt32 (System.String value, System.IFormatProvider provider) [0x00005] in /Library/Frameworks/Xamarin.iOS.framework/Versions/10.99.8.25/src/mono/mcs/class/referencesource/mscorlib/system/convert.cs:1121
at System.String.System.IConvertible.ToInt32 (System.IFormatProvider provider) [0x00000] in /Library/Frameworks/Xamarin.iOS.framework/Versions/10.99.8.25/src/mono/mcs/class/referencesource/mscorlib/system/string.cs:3372
at System.Convert.ChangeType (System.Object value, System.Type conversionType, System.IFormatProvider provider) [0x0011a] in /Library/Frameworks/Xamarin.iOS.framework/Versions/10.99.8.25/src/mono/mcs/class/referencesource/mscorlib/system/convert.cs:361
at MonoTouch.Design.UIKitParser.ChangeType (System.Object value, System.Type type) [0x00055] in /Users/builder/data/lanes/5153/70936af1/source/XamarinVS/External/md-addins/Xamarin.Designer.iOS/MonoTouch.Design.Server/TypeSystem/Loader.cs:125
at MonoTouch.Design.Parser.ParseElement (System.Object result, MonoTouch.Design.ParseContext context) [0x00109] in /Users/builder/data/lanes/5153/70936af1/source/XamarinVS/External/md-addins/Xamarin.Designer.iOS/MonoTouch.Design.Shared/Parser.cs:1102
If I replace numberOfLines="0.0" with numberOfLines="0" in storyboard file manually, this error goes away.
I was unable to reproduce this using the latest versions of the tooling (15.4.3). Would you please update to these versions and let me know if you can reproduce the issue? It looks like you are currently still using an old web preview of Xamarin.iOS (10.99).
You can update Visual Studio on Windows to 15.4.3:
You will want to update the Mac using the Updater:
You may also need to update Xcode using the Mac App Store.
This bug still can be observed with latest stable Visual Studio version (15.4.3) and latest xcode version (9.1). Zero number of lines for label is saved as '0.0'.
I can reproduce this bug even in a sample project created from Visual Studio (Cross Platform App -> Native).
Thanks for confirming. Could you please attach a project that I can use to reproduce this? You can delete the bin/obj and /packages folders to reduce the zip size. I was unable to reproduce the issue so far.
Because we have not received a reply to our request for more information, we are marking this issue as RESOLVED→NORESPONSE. If you are still encountering this issue on the latest Visual Studio 15.6 Preview 3, please don’t hesitate to reopen the ticket with the requested information. Thanks!