Category:Software companies of India
Category:Companies based in Hyderabad, India
Category:Software companies of India
Category:Enterprise software
Category:Privately held companies of India
Category:Companies established in 1999
Category:1999 establishments in IndiaQ:
Pass a bitmap to another activity
I want to pass a bitmap from one activity to another.
So, I have the following code:
First Activity:
public void onActivityCreated(Bundle savedInstanceState) {
super.onActivityCreated(savedInstanceState);
setContentView(R.layout.activity_main);
Bitmap bitmap = BitmapFactory.decodeResource(getResources(),R.drawable.3);
//Bitmap bitmap = BitmapFactory.decodeResource(getResources(),R.drawable.2);
Intent intent = new Intent(this,2Activity.class);
intent.putExtra("bitmap", bitmap);
startActivity(intent);
finish();
}
and then in 2 activity:
Bitmap bitmap = (Bitmap) intent.getSerializableExtra("bitmap");
but this doesn't work, I don't get anything in the bitmap...
any help?
A:
You can use Intent-Params for this, but as you only pass one parameter the easiest approach is to put it into a Shared Preference.
This is the code for the first activity:
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
// here you set up the Bitmap
// you should set up the OnClickListener in the normal onClick(View) way
// after setting up the Bitmap to show up in the Second Activity
setBitmap(R.drawable.3 01e38acffe
Communion in Sacred Space: An Apocalyptic Symbol
V
Sham Vakil, Poetry by Sham Vakil at A Hundred Thousand Suns.
References
Category:Indian literature
Category:Cultural history of India
Category:Cultural history of PakistanQ:
How to get total sum of a column from the subquery?
I have below SQL query :
SELECT
SC.SEQUENCE_CODE,
SS.SYSTEM_NAME,
ISNULL(SP.SYSTEM_ID,0) AS PRIMARY_SYSTEM_ID,
ISNULL(SP.PARENT_SYSTEM_ID,0) AS PARENT_SYSTEM_ID,
ISNULL(SP.SYSTEM_FLAT_NAME,0) AS SYSTEM_FLAT_NAME,
ISNULL(SP.SYSTEM_FLAT_FILE_NAME,0) AS SYSTEM_FLAT_FILE_NAME,
ISNULL(SP.SYSTEM_EXTERNAL_NAME,0) AS SYSTEM_EXTERNAL_NAME,
ISNULL(SP.SYSTEM_EXTERNAL_FILE_NAME,0) AS SYSTEM_EXTERNAL_FILE_NAME
FROM
(
SELECT
SC.SEQUENCE_CODE,
SS.SYSTEM_NAME
Related links:
Comments