Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 203363
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T17:22:19+00:00 2026-05-11T17:22:19+00:00

I am wondering if anyone has used the userInteractionEnabled method on a UILabel to

  • 0

I am wondering if anyone has used the userInteractionEnabled method on a UILabel to allow the label to act like a button (or just to fire off a method). Any help would be greatly appreciated. Cheers!

Update (4/30/09 @1:07pm) Clarification: I have a standard InfoButton and next to it I want to place a label with the text “settings” and I would like the label to function like the button (which flips over to a settings screen. So, basically I need to tie the already defined showSettinsView to the “infoLabel” label; a user clicks on the infoButton or infoLabel and the method fires off.

The infoButton is already working and is using an IBAction to trigger the method. I would like to know how to wire up the label to implement the same method. That is all. Cheers!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-11T17:22:20+00:00Added an answer on May 11, 2026 at 5:22 pm

    userInteractionEnabled is not a method but a property. But I think you will want to set this to YES to allow events to get through to the UIView superview.

    What you might want to do is override the touchesBegan:withEvent: method of the UIView that contains your UIButton and UILabel subviews.

    Within this method, test if any of the UITouch touches fall inside the bounds of the UILabel.

    That is, does the CGPoint element [touch locationInView] intersect with with the CGRect element [infoLabel bounds]? Look into the function CGRectContainsPoint to run this test.

    If so, then fire off an NSNotification that calls the same IBAction selector as the UIButton.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 178k
  • Answers 179k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Run your application with javaw.exe rather than java. If you're… May 12, 2026 at 3:45 pm
  • Editorial Team
    Editorial Team added an answer Silverlight is a different CLR than .NET, so the assembles… May 12, 2026 at 3:45 pm
  • Editorial Team
    Editorial Team added an answer You just use the '<front>' for the url and the… May 12, 2026 at 3:45 pm

Related Questions

I have a genealogical database (about sheep actually), that is used by breeders to
I have started using aspects for parameter validation in our development framework. It works
I am attempting to read a large XML document and I wanted to do
I am developing a cocoa application that will be making heavy use of both

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.