i declare a variable in one class and want to use that variable in the same class but i want to put data into the variable in a different class. How can i fill a variable from another class?
EDIT:
I have this in one class:
NSManagedObject *managedObject = [self.fetchedResultsController objectAtIndexPath:indexPath];
NSString *aString = [[managedObject valueForKey:@"data"] description];
Then i have this in another class:
NSString *stalklabel = aString;
NSURL *url = [NSURL URLWithString:[NSString stringWithFormat:@"http://news.search.yahoo.com/rss?ei=UTF-8&p=%@&fr=news-us-ss", stalklabel, nil]];
In your first class create a method that returns that string.
In the second class, call that method.