[MonoTouch] trouble getting change a property of an outlet in a any new method

Jeff Stedfast jeff at xamarin.com
Thu Dec 15 10:54:34 EST 2011


Hi Salmo,

Unfortunately I think the reason people haven't answered is because they
don't really understand the question.

I've Cc'd Rodrigo Kumpera (who is also from Brazil) so maybe you can tell
him your problem in your native language and he can translate it to those
on the MonoTouch and/or MonoDevelop teams so we can fix the issue.

Hope that helps!

Jeff

On Thu, Dec 15, 2011 at 5:46 AM, Salmo <salmo at chb.com.br> wrote:

>
> Hi guys,
>
> I'm having trouble getting change a property of an
> outlet in a  any new method, for example:
>
>        public partial class ViewApresentacao : UIViewController
>        {
>                ...
>                ...
>                public override void ViewDidLoad ()
>                {
>                        base.ViewDidLoad ();
>
>                        //my ImageView
>                        imgModelo.Image = UIImage.FromBundle
> ("Image/car.png");
>                }
>
>                //new method
>                public void Test(string pathImage)
>                {
>                        imgModelo.Image = UIImage.FromBundle (pathImage);
>                }
>                ....
>        }
>
> At viewDidLoad functions normally, but the second
> method (Test) did not, wanted to use it
> to update when a selected row in a table, it's all
> ok but when I call the method "Test", the error
> "object reference not set to an instance of an object"
> appears well in line with the outlet.
> Can someone help me?
>
> Sorry if I was not very clear, I'm from Brazil and I'm
> using google translate!
>
> Help pleaseee!!
>
> _______________________________________________
> MonoTouch mailing list
> MonoTouch at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/monotouch
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/monotouch/attachments/20111215/3e37148f/attachment.html 


More information about the MonoTouch mailing list