How to store UserID username in Titanium?

You can use the App. Properties API. Example, right from the docs.Titanium.App.Properties.

SetString("my_prop","cool").

If you are going to store the information in the properties, you should be aware that the is information persisted on the device. The use of properties for short term storage IMHO should be avoided if possible. You have two choices, one store your variables in the Titanium namespace Titanium.App.

Credentials = { "user" :"username", "pwd":"password123"}; Or create your own namespace and store your variable there. This will ensure you values are available throughout the application, but not stored on the device. There is an example on my blog here blog.clearlyinnovative.com/post/65191481....

That's what I have done eventually. Actually, I was referencing wrong object while retrieving, so I was getting wrong value. Thanks anyways.

– iMatoria Jun 19 at 2:41.

If(Ti.Facebook. LoggedIn) { if(Ti.App.Properties. HasProperty('fbid')) { var fbid = Ti.App.Properties.

GetString('fbid'); } } You can use the hasProperty to verify they have logged in in the past and when they do logout you can use the removeProperty so that your app assumes they haven't logged in and starts over.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions