Hey all,
I have created a function that will add people in a database, and I would like to use this function in my IBACTION method that is connected to a button.
Essentially all I have is:
- (IBAction)someFunction{
<other code>
addPerson"Person Name";
<other codee>
}
now for some reason it does not add the person into the DB, however when I copy the code out of the "Add Person" method and have it directly in the IBAction, it works... any ideas why?
The DB gets created/loaded when the app fires up, in the same class as the actions/methods.
Thanks so much!
I have created a function that will add people in a database, and I would like to use this function in my IBACTION method that is connected to a button.
Essentially all I have is:
- (IBAction)someFunction{
<other code>
addPerson"Person Name";
<other codee>
}
now for some reason it does not add the person into the DB, however when I copy the code out of the "Add Person" method and have it directly in the IBAction, it works... any ideas why?
The DB gets created/loaded when the app fires up, in the same class as the actions/methods.
Thanks so much!