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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T15:37:32+00:00 2026-06-13T15:37:32+00:00

I have a simple iOS app in which one class called Dictionary (.m and

  • 0

I have a simple iOS app in which one class called Dictionary (.m and .h) has several functions for building an NSArray of NSDictionary objects and then functions to manipulate that data structure. I have a UITableViewController class that has the table view delegate methods, but I can’t figure out how to create an instance of the Dictionary class in that UIViewController in order to be able to have all of the delegate methods talk to that instance of the class (e.g. when i call Dictionary *dictionary = [[Dictionary alloc] init] in the viewDidLoad method, I can’t access any of that instance in the cellForRowAtIndexPath delegate method. New to iOS programming and feeling very frustrated with it! Any help would be greatly appreciated.

  • 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-13T15:37:33+00:00Added an answer on June 13, 2026 at 3:37 pm

    Sounds like you need to declare dictionary as a member variable of your class.
    There are several ways to do this. The quickest is to put the following above the @implementation call in your .m file of your table view controller.

    @interface nameOftableViewControllerClass(){
        Dictionary *dictionary;
    }
    @end
    

    Make sure to replace nameOftableViewControllerClass with the actual name of your view controller class.
    Then, in view did load. you can call the following

    dictionary = [[Dictionary alloc] init];
    

    Then in the cellForRowAtIndexPath you can call any functions on the dictionary object.
    Don’t forget to put a release call in the dealloc method of your table view controller.

    -(void) dealloc {
         [dictionary release];
         [super dealloc];
    }
    

    hope this helps, hit my up if you have any more problems

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

Sidebar

Related Questions

I wrote simple iOS app which countdown the time til midnight. I have single
I have a simple class which does reverse geocoding, but it causes the app
I have lately been developing a very simple app for iOS with PhoneGap. All
I have simple class with width and height member fields which define number of
I am learning iOS and I have written a simple iPhone app using iOS
I have seen a slick method for upgrading user data from one iOS app
I'm writing an iPhone app (which will be my first ios app) that has
I have a very simple iOS app with a uiwebview loading a very simple
I have a simple app which adds a subview over the main view when
I am building an iOS App which displays video streams from a somewhat complex

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.