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 964845
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T01:53:49+00:00 2026-05-16T01:53:49+00:00

Is the first parameter supposed to be an object? A tutorial I’m following has

  • 0

Is the first parameter supposed to be an object? A tutorial I’m following has the first parameter being textFieldBeingEdited.text, where it is defined in the .h file as

UITextField *textFieldBeingEdited

Isn’t textFieldBeingEdited an object, and text is a property of that object?

The following code crashes:

[tempValues setObject:textFieldBeingEdited forKey:tagAsNum];

If I change it to the following then it doesn’t crash:

[tempValues setObject:textFieldBeingEdited.text forKey:tagAsNum];

That doesn’t make sense though since the first argument is supposed to be an object, and not a property.

  • 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-16T01:53:50+00:00Added an answer on May 16, 2026 at 1:53 am

    A property is syntactic sugar for a getter method that returns an object and optionally a setter method that takes an object. The text property of the UITextField object provides a getter method that returns an NSString object that can be stored in an NSDictionary.

    Essentially, a property provides two methods. For example, the methods implemented/synthesised by the text property may look like this (simplified for the sake of the example):

    - (NSString *) text
    {
        return text;
    }
    
    - (void) setText:(NSString *) newText
    {
        if (text != newText)
        {
            [text release];
            text = [newText copy];
        }
    }
    

    When you use object.text = @"Hello", it will actually send the setText: message with @"Hello" as the argument, and when you use NSString *value = object.text; it will actually send the text message, which returns an NSString object.

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

Sidebar

Related Questions

I have two arrays the first one has this structure Parameter Keys array array
EventDispatcher.addEventListener() expects first parameter for event type (parameter of String type). But the current
Via Function: myfunc Parameters: a - First parameter b - First parameter I can
strtok wont work correctly when using char *str as the first parameter (not the
I'm trying to do something like this http://myweb.com//page If first parameter is not present
var request = new WebClient(); request.DownloadFile(http://2nditeration.ca/Images/facebook.png, C:\tmp\filename.png); The first parameter is saying there are
I came across this in the book: wscanf(L%lf, &variable); where the first parameter is
Imagine I have a method: void Method(bool parameter){ if(parameter){ // first case } else
I'm using table values for the first time as a parameter to a function
PHP has some pretty inconsistent parameters for functions (e.g. sometimes first haystack , then

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.