Page 2 of 2

Re: System.ArgumentNullException Value cannot be null. Parameter name: type

Posted: Wed Mar 24, 2021 10:30 pm
by Pep
Hello,
are you able to reproduce the problem with a clean app ? If so, could you please attach to a this post the example app ?
Thanks

Re: System.ArgumentNullException Value cannot be null. Parameter name: type

Posted: Thu Mar 25, 2021 3:07 am
by 18286055

Re: System.ArgumentNullException Value cannot be null. Parameter name: type

Posted: Thu Mar 25, 2021 9:33 am
by Pep
Hello,
thanks for sending an example.
I've just checked it and I still not being able to reproduce the problem here. When does it happens to you? Should I do anything special ?
I've uploaded a gif animated of the test here.

Re: System.ArgumentNullException Value cannot be null. Parameter name: type

Posted: Thu Mar 25, 2021 3:26 pm
by 18286055
This is the stack trace:

Code: Select all

{System.ArgumentNullException: Value cannot be null.Parameter name: type 

at System.Activator.CreateInstance (System.Type type, System.Reflection.BindingFlags bindingAttr, System.Reflection.Binder binder, System.Object[] args, System.Globalization.CultureInfo culture, System.Object[] activationAttributes) [0x00003] in /Users/builder/jenkins/workspace/archive-mono/2020-02/android/release/mcs/class/referencesource/mscorlib/system/activator.cs:74  

at System.Activator.CreateInstance (System.Type type, System.Object[] args) [0x00000] in /Users/builder/jenkins/workspace/archive-mono/2020-02/android/release/mcs/class/referencesource/mscorlib/system/activator.cs:112  

at System.Security.Cryptography.CryptoConfig.CreateFromName (System.String name, System.Object[] args) [0x01002] in /Users/builder/jenkins/workspace/archive-mono/2020-02/android/release/mcs/class/corlib/System.Security.Cryptography/CryptoConfig.Mobile.cs:249 }
It only occurs when I create a TeeChart control (ChartView, Line, etc). Tools (Annotations, NearestPoint, etc) don't seem to trigger it.

Re: System.ArgumentNullException Value cannot be null. Parameter name: type

Posted: Fri Mar 26, 2021 10:01 pm
by 18286055
Just got new info: seems to be related to HotReload and TeeChart.PCL.Android.

Code: Select all

Assembly Ref addref TeeChart.PCL.Android[0x70d6fadb00] -> System.Core[0x70d6fe4be0]: 9
[HotReload] (2021-03-26 16:57:39.2): ERROR: Caught exception in OnAfterSave at 290: System.NullReferenceException: Object reference not set to an instance of an object.
   at Xamarin.HotReload.Vsix.XamarinHotReloadExtensionPackage.GetFileIdentityForDocument(String docPath) in D:\a\1\s\Source\Xamarin.HotReload.Vsix\XamarinHotReloadExtensionPackage.cs:line 316
   at Xamarin.HotReload.Vsix.XamarinHotReloadExtensionPackage.OnAfterSave(UInt32 docCookie) in D:\a\1\s\Source\Xamarin.HotReload.Vsix\XamarinHotReloadExtensionPackage.cs:line 277
   at Xamarin.HotReload.Vsix.XamarinHotReloadExtensionPackage.GetFileIdentityForDocument(String docPath) in D:\a\1\s\Source\Xamarin.HotReload.Vsix\XamarinHotReloadExtensionPackage.cs:line 316
   at Xamarin.HotReload.Vsix.XamarinHotReloadExtensionPackage.OnAfterSave(UInt32 docCookie) in D:\a\1\s\Source\Xamarin.HotReload.Vsix\XamarinHotReloadExtensionPackage.cs:line 277
**System.ArgumentNullException:** 'Value cannot be null.
Parameter name: type'

Re: System.ArgumentNullException Value cannot be null. Parameter name: type

Posted: Mon Mar 29, 2021 9:24 am
by Pep
Hello,

thanks for the info sent.
I've looked into it and have been able to reproduce it and found where the problem was.
It has been fixed now. We'll upload a new maintenance version within one or two days which will include this fix and others.

Thanks.