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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T09:09:23+00:00 2026-06-12T09:09:23+00:00

I am having some issues with my protocol & delegate that I have set

  • 0

I am having some issues with my protocol & delegate that I have set up in my app.
I am trying to return some data from a class back to a viewcontroller, however when I try to send it back nothing happens… The protocol method is never entered.

I have been over the way have set it up several times using this as a reference and just cannot see where I am making the error, So I thought if I share my code maybe someone here might be able to see what I cannot.

Heres the code I have written.

SendingClass.h

@protocol SearchViewCachedData <NSObject>
- (void)sendMyArray:(NSArray *)array;
@end
//..
    __weak id <SearchViewCachedData> SearchViewDelegate;
//..
    @property (weak, nonatomic) id <SearchViewCachedData> SearchViewDelegate;
//..

SendingClass.m

@synthesize SearchViewDelegate;

//..

[[self SearchViewDelegate]sendMyArray:dictionaryArray];

SearchView.h

@interface SearchViewController : UITableViewController <SearchViewCachedData> {

SearchView.m

- (void)sendMyArray:(NSArray *)array
{
    //Break point in here.. but its never reached.
}

Going abit bonkers here so any help what so ever 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-12T09:09:24+00:00Added an answer on June 12, 2026 at 9:09 am

    I have a feeling your delegate is not set

    Check to make sure searchViewDelegate is set to an instance value

    if (self.searchViewDelegate != nil) {
        [self.searchViewDelegate sendArray:array];
    }
    

    Also. Properties should have their first case lower case. Classes are the items that are Capitalized.

    amendment

    It may be getting set to nil by another part in code or you may not be setting it at all.

    where you synthesize your delegate you can create a setter as well.

    @synthesize searchViewDelegate = _searchViewDelegate;
    - (void) setSearchViewDelegate:(id<SearchViewCachedData>) searchViewDelegate{
        if (searchViewDelegate != searchViewDelegate){ // Add breakpoint here to see when set is called.
            searchViewDelegate = searchViewDelegate;
        }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Recently I was having some issues with a singelton class that was lazy initializing
I'm having some issues returning unique results from a table that has some repeating
Having some issues accessing my param tags from within actionscript. Essentially I have the
I am having some issues passing commands through to flash from javascript. My code
I'm having some issues to deserialize a Json array that follows this format: [
I am having some issues with a code that is occasionally and sporadically throwing
I'm having some issues with the data returned by CNCopyCurrentNetworkInfo and was wondering if
having some issues with a networking assignment. End goal is to have a C
Having some issues getting this MPMoviePlayerViewController to work. I have two sample URLs pointing
i'm currently having some issues by using the cakePHP data validation. I've tried to

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.