• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: A simple question about nsthread
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: A simple question about nsthread


  • Subject: Re: A simple question about nsthread
  • From: Andrea Salomoni <email@hidden>
  • Date: Thu, 1 Dec 2005 12:39:22 +0100

Thank you,

Il giorno 01/dic/05, alle ore 11:19, j o a r ha scritto:


On 1 dec 2005, at 11.02, Andrea Salomoni wrote:

Yes but if I declare the IBOutlet variable and I write [myvariable setStringValue:@"aString"]; I populate it...

No, you don't. In this case you call a method on the variable, you still haven't created the object that should "live in" the variable, or assigned the object to the variable.

You wouldn't do this:

NSDictionary *myDictionary;
[myDictionary setObject: @"SomeString" forKey: @"SomeKey"];

Try it out and see why!

Before using the variable, you need to give it a value:

myDictionary = [NSDictionary dictionary];
Yes I know it.
But the proble is that my variable is an Outlet....
How can I give a value to an Outlet?
I know an Outlet is a variable... but which is the reason why in the main thread the outlet exist and in secondary thread not?

The problem is that IBOutlet for some strange reason doesn't exist:
the if (nil != myvariable){
NSLog (@"doesn't exist");
}
return true... so the problem is that the outlet doesn't exist....

It's not strange at all. IBOutlets are typically populated for you when you load a nib file, and as long as you don't, they will remain empty (== nil).

j o a r


Thank you very much for your help
Andrea


_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden
  • Follow-Ups:
    • Re: A simple question about nsthread
      • From: Shawn Erickson <email@hidden>
    • Re: A simple question about nsthread
      • From: j o a r <email@hidden>
References: 
 >A simple question about nsthread (From: Andrea Salomoni <email@hidden>)
 >Re: A simple question about nsthread (From: j o a r <email@hidden>)
 >Re: A simple question about nsthread (From: Andrea Salomoni <email@hidden>)
 >Re: A simple question about nsthread (From: j o a r <email@hidden>)

  • Prev by Date: Re: more than one plist in a file.
  • Next by Date: Re: A simple question about nsthread
  • Previous by thread: Re: A simple question about nsthread
  • Next by thread: Re: A simple question about nsthread
  • Index(es):
    • Date
    • Thread