Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Want to store two variables permanently for an App in mobile OS

I am trying to develop an App in Titanium Appcelerator all I need in that app is that it should always run in the background and collect current GPS coordinates and send it to a server. All I want the App to permanently remember is IP and PORT Number of the server. If the mobile is switched off and then on again IP and Port should be there. I think For this two variables only I should not use a Database. Is their any Other way to store IP and Port Number permanently other than using a database ?
Thank you

like image 833
Nagri Avatar asked Nov 30 '25 09:11

Nagri


1 Answers

You can Try :-

// Set one time. this is work just like Database

Titanium.App.Properties.setString("ip",<value>);

// Get any where

Titanium.App.Properties.getString("ip","value");
like image 151
MRT Avatar answered Dec 01 '25 22:12

MRT