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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T11:38:51+00:00 2026-05-23T11:38:51+00:00

in File.h I have variable are: NSString *Category; in .m and .h I get

  • 0

in File.h

I have variable are:

NSString *Category;

in .m and .h

I get this error “Expected identifier or ‘(‘ ” on this line of code:

————————————.h

Category = [NSString stringWithUTF8String:(char *)sqlite3_column_text(selectStatement,3)];

[Categoryarray addObject:Category];

Category = [Categoryarray objectAtIndex:i];

sqlite3_bind_text(addStmt, 3, [Category UTF8String], -1, SQLITE_TRANSIENT); //! Receiver type 'Category'(aka 'struct objc_category *') is not Object..

Category is not an Object-C class name or alias

—————————————end

and in second class are show red mistake:
—————–.h sub class

IBOutlet UITextField *Category;

—————-.m sub class

if([Category.text isEqualToString:@""] || Category.text == nil){ // ! expect ";" in expression
    Category.text=@" ";
}

In code another line not wrong but only this line is wrong.

and im not sure why, can anyone help?

  • 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-23T11:38:51+00:00Added an answer on May 23, 2026 at 11:38 am

    I think you are experiencing a name clash. Category is defined in obj-class.h like this:

    typedef struct objc_category *Category;
    

    Hence, your error (from your comments):

    Receiver type ‘Category'(aka ‘struct
    objc_category *’) is not Objective-C
    class.

    Renaming your instance variable to something else should fix the issue (almost, keep reading).

    Also, your variable is a NSString and does not have a property text.

    if([Category.text isEqualToString:@""] || Category.text == nil){
        Category.text=@" ";
    }
    

    You can invoke those methods on the NSString directly like this:

    if([myString isEqualToString:@""] || myString == nil) {
        myString = @"";
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a variable in code that can have file path or url as
I have a file that contains this kind of paths: C:\bad\foo.c C:\good\foo.c C:\good\bar\foo.c C:\good\bar\[variable
I have a NSString member variable declared in the header file of the view
I have declared a variable NSString sessionId; in app delegate file for global usage.
I have a global NSString variable that I declared in my ViewController.m file, outside
I have a variable define as: set filePath=.\file.txt I'm writing a windows batch file.
I have a variable which has the directory path, along with the file name.
I have the following variable that accepts a file name: var xtr = new
I have script file where a command is stored in a variable First i
I have a GUID variable and I want to write inside a text file

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.