[MonoTouch] SIGSEGV while executing native code
Guido Van Hoecke
guivho at gmail.com
Fri Oct 7 09:44:25 EDT 2011
Hi Rolf,
On Fri, Oct 7, 2011 at 13:32, Rolf Bjarne Kvinge <rolf at xamarin.com> wrote:
> var button = new UIBarButtonItem {..
> When the method finishes executing, there is no reference to this button in
> managed code, so the GC determines that it can collect it. You need to
> ensure the button stays alive as long as necessary (usually done by using a
> class-level variable instead of a method variable)..
This does not fix the problem. In fact, in the original app where I
bumped into the problem, each of the four buttons are class level
variables. As mentionned by Steott in the other reply, I got it fixed by
removing the 'using' clause.
Still, thanx for your help,
Guido.
More information about the MonoTouch
mailing list