We are having two crash logs from our users that have the same error, namely operations on objects that have been GCed. I am having a hard time resolving the issue since it isn't possible to reproduce. We are not using the SGEN garbage collector since it has yet to be marked as stable. So basically my questions are:
Are there any examples out there on how to use iAd on MonoTouch in a GC friendly manner? Our main bug report is due to an iAd banner that is shown on a details viewcontroller. We are keeping a reference to the banner as a class variable to avoid it being GCed, so really not sure on how to track this down. Maybe add the banner as a static variable would be possible, or is that a bad idea?
Is SGEN ready for release soon and could that help in the situation above? We have a lot of users and I don't want to release a version with sgen if there are known issues with it :-)
The tutorials on this site are great, but it would really be nice on a tutorial on memory management. Like: How do you have events on buttons inside a UITableCell without the buttons being GCed?
Device info: iPod touch - Unknown - 6.0, timezone=0, 22:18:29: Selector invoked from objective-c on a managed object of type MonoTouch.iAd.ADBannerView+_ADBannerViewDelegate (0x54AE810) that has been GC'ed - at MonoTouch.ObjCRuntime.Runtime.ConstructNSObject (IntPtr ptr, IntPtr klass) [0x00000] in <filename unknown>:0 at MonoTouch.ObjCRuntime.Runtime.GetNSObject (IntPtr ptr) [0x00000] in <filename unknown>:0 at MonoTouch.ObjCRuntime.Runtime.GetNSObjectWrapped (IntPtr ptr) [0x00000] in <filename unknown>:0 at (wrapper native-to-managed) MonoTouch.ObjCRuntime.Runtime:GetNSObjectWrapped (intptr) at MonoTouch.UIKit.UIApplication.Main (System.String args, System.String principalClassName, System.String delegateClassName) [0x00000] in <filename unknown>:0 at NDC2010.NDC2010Application.Main (System.String args) [0x00000] in <filename unknown>:0