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

  • SEARCH
  • Home
  • 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 8805347
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T01:50:36+00:00 2026-06-14T01:50:36+00:00

I am a beginner in Xcode, and I have a problem. I have 2

  • 0

I am a beginner in Xcode, and I have a problem.
I have 2 buttons:

- (IBAction) HIGH1: (id) sender
- (IBAction) HIGH2: (id) sender

When the user clicks the HIGH1button, I want to change the background (with image) of the button HIGH2.

How can I achieve this?

  • 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-06-14T01:50:38+00:00Added an answer on June 14, 2026 at 1:50 am

    You need to create IBOutlet for the buttons to change them.

    Control+drag the buttons from Interface Builder to the .h file to create the outlets. Something like this:

    @property (weak, nonatomic) IBOutlet UIButton *HIGH1;
    @property (weak, nonatomic) IBOutlet UIButton *HIGH2;
    //Dont forget to @synthesize
    

    On the IBAction method you then call:

    - (IBAction) HIGH1: (id) sender
    {
        self.HIGH2 setBackgroundImage:[UIImage imageNamed:@"myButtonImage"] forState:UIControlStateNormal];
    }
    

    Make sure you have an image with the name you choose in your application bundle, and that the IBOutlet to the buttons is properly connected (The gray circle on the left size of the IBOutlet must have a small black circle inside it)

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

Sidebar

Related Questions

I an a beginner. I have problem running cocos2d tests in Xcode 4.2 since
Beginner iOS dev here. I have a problem in my array. Im making an
Python beginner here, I have a list of lists and want to refer to
I have Xcode 3.2.6 and Instruments 2.7 and I am beginner with those applications.
I have Xcode 4.2 and I am a complete beginner. One of my files
I'm a beginner in xcode, and I want to make an projec where I
VS beginner question. How to change parent control of a control? Example. I have
I am a beginner in xcode, I want to know how can I implement
I'm a complete beginner to Apple's Xcode, but I have followed the Xcode documentation
i'm beginner in coding in Xcode. What i want to get is a tableview

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.