I have just started android.
I just want to know that how can i call activity class from other java class.
i just want to pass class object to activity class.
anyhelp please.
public class GsonParser extends Activity {
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
MagazineThread thread=new MagazineThread();
thread.start();
}
public GsonParser(JsonMagazineParser Obj)
{
}
}
and i am just doing like from other class.
GsonParser obj=new GsonParser(this);passing obj to activity class.how can i achieve that.
can u please tell me.
Have a look at the documentation: http://developer.android.com/reference/android/app/Activity.html
specifically startActivity and startActivityForResult