How to keep application session and store data in sqlite in iphone app?
There are 4 buttons that let user to click. When he clicks one of the buttons, I want to save the button id or value in application session until he closes the app.
How can I do it?
Secondly, how can I insert, update, delete, select data in sqlite in iphone app?
CiPhoneSwift Programming
Last Comment
techques
8/22/2022 - Mon
pgnatyuk
I think you need to split the question for two. There is no any relation between them
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
I think I do not need to use sqlite. How can I keep the value in a multi dimension arrays?
msdcdev
If you just need it for the life of the application (not after exit/relaunch), just use an app delegate variable. Otherwise, create a core data entity and persist/retrieve the objects as necessary. Here's a tutorial:
Multi dimension arrays can be solved with related entities. For example, a widget group has widgets, and each widget has components. You'd model a WidgetGroup, a Widget, and a WidgetComponent entity, and model the relationships accordingly (setting the multiplicity to one-to-many, or even many-to-many).
Experts Exchange is like having an extremely knowledgeable team sitting and waiting for your call. Couldn't do my job half as well as I do without it!