• 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
Custom PopUpButton: IB Connection not holding at runtime
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Custom PopUpButton: IB Connection not holding at runtime


  • Subject: Custom PopUpButton: IB Connection not holding at runtime
  • From: Adam Raney <email@hidden>
  • Date: Mon, 15 Aug 2005 09:24:00 -0500

Hello all,

I have a pop-up button that I intend to use to insert HTML tags into a text field for the user.

I intend to have a different pop-up button for each field (three fields total), that all share the same menu (list of tags to insert), and will perform the exact same action, just aimed at a different text field.

To that end, I sub-classed NSPopUpButton to ACRPopUpButton, and added a NSTextField IBOutlet "target", and a getter method to retrieve the target.

All three popup buttons are connected to my custom Controller class to call it's insert: method. This method then calls the 'target' method from the sender (the ACRPopUpButton) to retrieve the NSTextField target to place the text into it. (for testing purposes, I simply have a "setStringValue:" method placing "INSERT" into the text field.

The problem is, when I run this through the debugger, the ACRPopUpButton's target is not set (0x0), even though I have it connected in IB.

Is there some simple step I have missed to set this up, or am I going about this entirely wrong? Why wouldn't the IBOutlet connection establish? Do I need to change something in the ACRPopUpButton's init method?
_______________________________________________
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
  • Prev by Date: Re: path name from Apple Event
  • Next by Date: Can't End A Process
  • Previous by thread: Re: IB strangeness - way to manually edit connections outside of IB?
  • Next by thread: Can't End A Process
  • Index(es):
    • Date
    • Thread