Keep in mind that the "FirstTime" value in B4A refers only to the first time that particular activity was shown for a new app "session" not a new app "installation". Meaning, if the user runs the app then exits the app after installing the app. The next time the user runs the app "FirstTime" will be set to True again.
What I do (in B4A) to detect if an app has been run for the very first time after an installation is use a preference setting:
B4X:
Sub Process_Globals
Dim PrefManager As PreferenceManager
End Sub
If PrefManager.GetString("FirstRunAfterInstall") = "" then 'it is first run
PrefManager.SetString("FirstRunAfterInstall", "No") 'so set value so won't be first run anymore
... [your first-run code here] ...
end if
After doing a search, there appears to be a Preference manager class for iOS that you could use:
Sub Activity_Create can be called many times, because you need to initialize Globals of the Activity (not Process_Globals) every time again. In B4i Application_Start is only called once, when the app starts. That's why you don't need the "FirstTime" parameter.
Private kvs As KeyValueStore
Private Sub Application_Start (Nav As NavigationController)
If File.Exists(File.DirDocuments, "Ini.dat") = False Then
kvs.Initialize(File.DirDocuments, "Ini.dat")
kvs.Put("value1",0)
End If
kvs.Initialize(File.DirDocuments, "Ini.dat")
If kvs.Get("value1")<1 Then '"1" is a mark that shows the times of app updating.
'your action
kvs.Put("value1",1)
else
'other action
end if
End sub
Private Sub Application_Start (Nav As NavigationController)
kvs.Initialize(File.DirDocuments, "Ini.dat")
If kvs.ContainsKey("already ran") = False Then
kvs.Put("already ran", True)
'first time
End If
End sub