tags:

views:

27

answers:

1

I write code below but it gives warning.. I identified dbdesc as a NSString but nothing changes.. How will I handle with this type of warnings?

**[self.searchDetailViewController setText:appDelegate.dbdesc];**

warning:'searchDetailViewController' may not respond to 'setText:' (Messages without a message method signatures will be assumed to return (id) and accept '...'as arguments )

+1  A: 

The problem is because the compiler is not aware of the 'setText' method of your searchDetailViewController property.
Be sure that you defined the method in your header (.h), within the class interface, and that you include the header.
It has nothing to do with the type of your dbdesc variable.

Macmade
I figured it out by identifying a varible IBOutlet for searchDetaiViewController.h drag it into the text field in .xib. Then called it as a searchDeatilView.variable setText: bla bla ... So I can display the value on my xib