-
Notifications
You must be signed in to change notification settings - Fork 66
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
v 1.3.1 Crash - Xamarin - Targeting 13.2 IOS #77
Comments
Which version of BTProgressHud? |
As title BTProgressHUD 1.3.1 |
Same problem . System.NullReferenceException: Object reference not set to an instance of an object |
Hi Guys, think this is a problem with images not being included. Whenever i called ShowSuccessWithStatus i would get a null ref exception, this was due to the SuccessImage being null. I downloaded the library and moved the images to my own resources folder and it fixed the problem for me. The strange part was when i added the BTProgressHud folder to my project the images still had a build action of BundleResources but still caused the null ref exception. They did not load in correctly until i added them to my own Resources folder. Think this is related |
@tony98789 looks like you are right. Tested #76 though and it doesn't seem to solve the issue. Will investigate this further. @Redth do you have any idea, why BundleResources don't make it into the DLL? |
I think they may only get included if it’s a binding project. You might have to add a .targets file to the nuget package and include the assets directly in the nupkg and add the |
@Redth I've just been working a bit on this. I managed to get the images and .targets file added to the NuGet package and the images seem to get included in the built IPA file when referencing the produced NuGet. However, it still doesn't seem to pick up the images when trying to load them from bundle. I see the images on the simulator file system. I added a file called <Project>
<ItemGroup>
<BundleResource Include="$(MSBuildThisFileDirectory)\BTProgressHud\error_7.png" />
<BundleResource Include="$(MSBuildThisFileDirectory)\BTProgressHud\error_7@2x.png" />
<BundleResource Include="$(MSBuildThisFileDirectory)\BTProgressHud\error.png" />
<BundleResource Include="$(MSBuildThisFileDirectory)\BTProgressHud\error@2x.png" />
<BundleResource Include="$(MSBuildThisFileDirectory)\BTProgressHud\success_7.png" />
<BundleResource Include="$(MSBuildThisFileDirectory)\BTProgressHud\success_7@2x.png" />
<BundleResource Include="$(MSBuildThisFileDirectory)\BTProgressHud\success.png" />
<BundleResource Include="$(MSBuildThisFileDirectory)\BTProgressHud\success@2x.png" />
</ItemGroup>
</Project> I don't really see what else should be needed for this to work? |
BTProgressHUD.1.3.2-bugfix-missing-assets.1.zip Here is a screenshot of the package contents exploring with NuGet Package Explorer. I've also attached a NuGet package (just rename to .nupkg) |
We are getting isolated crashes in some view controllers. Code wise, nothing has changed in at least two years on these controllers. At this point we are still trying to track down exactly how it is happening.
ProgressHUD.ShowImageWorker (UIKit.UIImage image, System.String status, System.TimeSpan duration)
ProgressHUD+<>c__DisplayClass26_0.b__0 ()
NSActionDispatcher.Apply ()
(wrapper managed-to-native) ObjCRuntime.Messaging.objc_msgSend(intptr,intptr,intptr,intptr,bool)
NSObject.InvokeOnMainThread (System.Action action)
ProgressHUD.ShowImage (UIKit.UIImage image, System.String status, System.Double timeoutMs)
BTProgressHUD.ShowSuccessWithStatus (System.String status, System.Double timeoutMs)
DeleteStoresGridDelegate+<>c__DisplayClass24_0.b__0 ()
NSActionDispatcher.Apply ()
(wrapper managed-to-native) UIKit.UIApplication.UIApplicationMain(int,string[],intptr,intptr)
UIApplication.Main (System.String[] args, System.IntPtr principal, System.IntPtr delegate)
UIApplication.Main (System.String[] args, System.String principalClassName, System.String delegateClassName)
Application.Main (System.String[] args)
The text was updated successfully, but these errors were encountered: