Data readable by two apps

by Viktor Linder » Sat, 08 May 2010 14:51:37 GMT


Sponsored Links
 Hi!
Is it possible to share files between two apps?

My scenario is this: I want to create a free/demo version of my game
and a complete version. The player should be able to play the free
version, then upgrade to the complete and continue where the free
version ended - ie. the complete version would need to load a savegame
created by the free version.

All answers appreciated!

Best regards,
Viktor Linder

--



Data readable by two apps

by Mark Murphy » Sat, 08 May 2010 18:26:51 GMT


 


Yes, if they are signed by the same signing key and use the same user ID
-- see the android:sharedUserId attribute of the <manifest> element:

 http://developer.android.com/guide/topics/manifest/manifest-element.html 

-- 
Mark Murphy (a Commons Guy)
 http://commonsware.com  |  http://github.com/commonsguy 
 http://commonsware.com/blog  |  http://twitter.com/commonsguy 

Android Development Wiki:  http://wiki.andmob.org 

--


Sponsored Links


Data readable by two apps

by TreKing » Mon, 10 May 2010 05:51:22 GMT


 




You could also save to the SD card, if you don't mind the data being
"public".

-------------------------------------------------------------------------------------------------
TreKing - Chicago transit tracking app for Android-powered devices
 http://sites.google.com/site/rezmobileapps/treking 

--



Other Threads

1. listDivider in 2.0

In 1.5, 1.6 this:
--
<ImageView xmlns:android="http://schemas.android.com/apk/res/android"
        android:src="?android:attr/listDivider" android:layout_height="1dp"
        android:layout_width="fill_parent" />
--
renders into the same divider used in ListViews.
Now, under 2.0 it renders as a dot.
What has changed and how can I fix it?

TIA.

-- 

2. Why activity Icon is not removed from launcher

hi,
   I'm trying to remove activity icon from launcher panel. I'm using
firmware 1.5. But nothing seems to work. I'm not receiving any error but
activity icon is not removed. Following is the code


public class HelloActivity extends Activity {

public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
       setContentView(R.layout.hello_activity);
}


    public void onDestroy() {
        super.onDestroy();
        disbaleActivity();
}

    private void disbaleActivity(){
        ComponentName receiver = new
ComponentName(getApplicationContext(),
        "HelloActivity.class");
        PackageManager pm = getPackageManager();
        pm.setComponentEnabledSetting(receiver,
PackageManager.COMPONENT_ENABLED_STATE_DISABLED,
                    PackageManager.DONT_KILL_APP);

    }
}


I've set following permission in manifest file
<uses-permission
android:name="android.permission.CHANGE_COMPONENT_ENABLED_STATE" />

and following is portion of activity in manifest file

      <activity android:name="HelloActivity">
            <intent-filter>
                <action android:name="android.intent.action.MAIN"/>
                <category android:name="android.intent.category.LAUNCHER"/>
            </intent-filter>
        </activity>


Please help me to resolve the issue. According to documentation it should
work but it doesn't. I've tried calling disbaleActivity() even from
OnCreate() method but no success :-(

Regards,
shaz

-- 

3. Android 2.0 setImageResource(R.drawable.my_icon)

4. Showing ellipsis in a TextView?

5. 绛斿: hiding a forcibly o pened soft keyboard...

6. hiding a forcibly opened soft keyboard...

7. Picture say a thousand word