user3257386
user3257386

Reputation: 284

how can I input information data when app is in first startup?

I want input data in internal storage of my app when my app installed in new device & never change(delete & update &insert). my information is heavy & if I input my information in oncreate() every time that user open my app information will be make again & I don't like it.how can I do it?

Upvotes: 0

Views: 126

Answers (2)

David C Adams
David C Adams

Reputation: 1973

Create a class that is a Broadcastreceiver and register it in your manifest to receiver Intent.ACTION_PACKAGE_INSTALL actions. It will be called only when the application is installed.

Upvotes: 2

Roman Black
Roman Black

Reputation: 3497

You can use assets folder and put your heavy data there. It will be installed with application package. You can find information about that here.

Upvotes: 0

Related Questions