how to use reload data in table view while working with two view?
<p>I have two classes. In my first class i have table view which contains list of countries. And in my second view i have a picker which contain sorting by name. And i have button in my first class. On this button click i go on second class. In second class when i click on picker like sorting by name then the picker value store into <code>NSMutableString</code>. So i want that when i go back to my first view i want to show list according to the second class picker value. I use table reload in the <code>viewWillAppear</code> method of first view but its not working. Sometimes it crashes.</p>

<pre><code> -(void)viewWillAppear:(BOOL)animated
    {

        if(secondClassObj.isActStrPicker&gt;=0)
        {

            sortByResultStr=[[NSString alloc]init];
            sortByResultStr=[secondClassObj  pickerValueStr];
            NSLog(@"picker class value of sorting  string fetech %@ if part sssssss",sortByResultStr);
        }
        else
        {
            //the else part is not working
            NSLog(@"picker class value fetech %@ else part sssssss",[cmpnyPickCheckObj isActStrPicker]);

        }
        [countrytableView reloadData];
    }
</code></pre>

<p>And i want that table shows value according to isActStrPicker(string) when i come back on this first view.
Thanks for helping me</p>
