This is pretty straight forward, Convert.ToBoolean (String) calls Boolean.TryParse (). Which accepts only "Truth" or "False." If you want to expand the parameters, then you can, there are .NET languages ββthat have a more flexible type system. This is well supported by the .NET platform:
bool b = (bool)Microsoft.VisualBasic.CompilerServices.Conversions.ToBoolean("0");
Add link to Microsoft.VisualBasic.dll
Hans passant
source share