How to declare global variables in Android?

I am creating an application which requires login. I created the main and the login activity. In the main activity onCreate method I added the following condition: public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); … loadSettings(); if(strSessionString == null) { login(); } … } The onActivityResult method which is executed when the login form terminates … Read more

How can I unset a JavaScript variable?

I have a global variable in JavaScript (actually a window property, but I don’t think it matters) which was already populated by a previous script, but I don’t want another script that will run later to see its value or that it was even defined. I’ve put some_var = undefined and it works for the … Read more