1

Closed

Format string Exception:

description

On Windows 8.1 I have this

Eccezione non gestita: System.FormatException: Formato della stringa di input non corretto.
 in System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal)
 in System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info)
 in System.Byte.Parse(String s, NumberStyles style, NumberFormatInfo info)
 in Mono.Cecil.AssemblyNameReference.Parse(String fullName)
 in ILSpy.BamlDecompiler.CecilTypeResolver.GetTypeByAssemblyQualifiedName(String name)
 in Ricciolo.StylesExplorer.MarkupReflection.XmlBamlReader.FormatPropertyDeclaration(PropertyDeclaration propertyDeclaration, Boolean withPrefix, Boolean useReading, Boolean checkType)
 in Ricciolo.StylesExplorer.MarkupReflection.XmlBamlReader.ReadPropertyWithExtension()
 in Ricciolo.StylesExplorer.MarkupReflection.XmlBamlReader.ProcessNext()
 in Ricciolo.StylesExplorer.MarkupReflection.XmlBamlReader.ReadInternal()
 in System.Xml.Linq.XContainer.ReadContentFrom(XmlReader r)
 in System.Xml.Linq.XContainer.ReadContentFrom(XmlReader r, LoadOptions o)
 in System.Xml.Linq.XDocument.Load(XmlReader reader, LoadOptions options)
 in Obfuscar.Obfuscator.GetXamlDocuments(AssemblyDefinition library)
 in Obfuscar.Obfuscator.RenameTypes()
 in Obfuscar.Obfuscator.RunRules()
 in Obfuscar.Program.Main(String[] args)
Anyone can help me?
thanks
Closed Jun 19 at 2:03 PM by lextm

comments

lextm wrote May 25 at 9:42 AM

It seems that you are obfuscating something with XAML.

Note that only WPF is supported (best efforts) while Windows Store/Windows Phone apps are not supported at all.

If your assembly is indeed WPF, you have to somehow share it with me so that I can do further analysis. You can reach me via support@lextm.com.

lextm wrote Jun 16 at 12:16 PM

This has been identified as a bug in ILSpy. Will investigate further to see how to fix it.

lextm wrote Jun 19 at 2:03 PM

This is a bug in ILSpy BAML reader, and I sent a pull request to ILSpy with the fix.

Obfuscar 2.0.1 beta contains the fix,

https://www.nuget.org/packages/Obfuscar/2.0.1-beta