Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>You can use the delegate method of UITextField named </p> <pre><code>-(BOOL)textFieldShouldReturn:(UITextField *)textField { [textField resignFirstResponder]; return YES; } </code></pre> <p>this method is get called when you press the return key after putting the text in UITextField in this method you can call one method say -(void)fetchDataFromMysql </p> <p>after call to this method your code will look like </p> <pre><code>-(BOOL)textFieldShouldReturn:(UITextField *)textField { [self fetchDataFromMysql]; [textField resignFirstResponder]; return YES; } </code></pre> <p>in fetchDataFromMysql method retrieve the names of recipes from Mysql store that retrieved names of recipes in the array that you have used to plot the names of the recipes in tableView say "recipeNameAry".</p> <p>so when the user will enter the search key for example pizza , you will get the recipes of pizza from Mysql ,we store that recipes in the "recipeNameAry" and now the time to update your tableView of recipe names so, after this call the method named "reloadData" for updating tableView , after calling this method your code will look like </p> <pre><code>-(BOOL)textFieldShouldReturn:(UITextField *)textField { [self fetchDataFromMysql]; [recipeNameTableView reloadData]; //here recipeNameTableView is the name of your tableView. [textField resignFirstResponder]; return YES; } </code></pre> <p>it will update your tableView with the recipes belonging to pizza or whatever. </p> <p><strong>NOTE</strong> :- First of all add the UITextFieldDelegate to your .h file like </p> <pre><code>#import &lt;UIKit/UIKit.h&gt; @interface contact : UIViewController &lt;UITableViewDataSource,UITableViewDelegate,UITextFieldDelegate&gt; { } @end </code></pre> <p>and in your XIB add the delegate to your UITextField with your FileOwner </p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload