If you are using Internet Explorer, please remove blackberry.com from your compatibility view settings.

Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Android™ Runtime Development

Reply
New Member
stephen_lacey
Posts: 1
Registered: ‎02-06-2012
My Device: Playbook Virtual Machine
My Carrier: N/A

Porting a basic app from Android to BB

Hi,

 

I'm new to this and am just porting my very first app across. Sorry if I'm asking a dumb question, but I have searched and cannot find the answer online.

 

Mostly tings have gone ok, although i find the virtual playbook unresponsive and the whole deployment/integration with eclipse to be buggy and unreliable.

 

Anyhoo, Everything more or less works in my app now except for 1 feature. My app uses an intent to allow the users to select a file from the filesystem. I accomplished this with the following code in the Android version of the app:

 

Intent intent = new Intent(Intent.ACTION_GET_CONTENT);
intent.setType("file/*");
startActivityForResult(intent,vcdSettings.FILE_DIALOGUE_PIC);

 

 

The app throws the following error in the Playbook VM:

Intent not supported

Intent {act=android.intent.action.GET_CONTENT typ=file/*}

 

Any thoughts or help on how to get this to work would be greatly appreciated.

 

Regards,

 

Stephen

 

Please use plain text.
Trusted Contributor
NGeldenhuys
Posts: 176
Registered: ‎04-12-2012
My Device: Bold 9780 & Curve 8250
My Carrier: vodacom

Re: Porting a basic app from Android to BB

hello 

 

Did you ever find the the blackberry function for intent?

 

Thank you

Please use plain text.
New Developer
jordaan0_gmail
Posts: 23
Registered: ‎08-03-2012
My Device: BlackBerry Playbook, BlackBerry 10 dev alpha device
My Carrier: mtn

Re: Porting a basic app from Android to BB

i had this same issue the work around was to modify the manifest mine looked like this

 

 

  <activity
            android:name=".mainActivity"
            android:label="@string/app_name" >
            </activity>

 

place it right below the main intent

 

 

 

 

    " <application
        android:icon="@drawable/button_unpressed"
        android:label="@string/app_name" >
        <activity
            android:name=".splash"
            android:label="@string/app_name" >
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

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

 

 please like if it worked

 

Please use plain text.
Developer
moniko17
Posts: 216
Registered: ‎08-23-2012
My Device: Javelin 8900
My Carrier: Axis

Re: Porting a basic app from Android to BB

in blackberry playbook sometime can run android application but cannot run all application, maybe this require different code for running in your playbook

Please use plain text.