Android :: App Crashing On HTC Magic Launching Camera Intent

Jul 15, 2009

Wine by the Bar app (free in Android Market) is crashing on the HTC Magic.What intent settings/extras are needed to successfully launch ACTION_IMAGE_CAPTURE on HTC Magic?intent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE);App works fine on G1.Also need proper intent for choosing an picture already on the phone, and a cropping intent.

Android :: App crashing on HTC Magic launching camera intent


Android :: Launching My App Using Intent URI

Aug 25, 2010

I know this has been asked a lot of times in StackOverflow already, but I haven't quite found a solution yet. My app sends an email with a link in it that when clicked should launch the app. According to @hackbod, the best way to do it is to make use of the Intent URI (see this). Here's my code that sets the intent and puts it in the email body: Code...

View 1 Replies View Related

Android :: Launching M3u Playlist With Intent?

Aug 16, 2009

Is there a way to launch a playlist whith intent? I can retrieve the path of the m3u playlist with: Cursor cursor = context.getContentResolver().query (MediaStore.Audio.Playlists.EXTERNAL_CONTENT_URI, null, null, null, null); cursor.getString(cursor.getColumnIndex (MediaStore.Audio.Playlists.DATA)); But, I can't launch this m3u file neither with Intent nor with MediaPlayer.

View 5 Replies View Related

Android :: Launching Intent Can't Find Activity

Jul 2, 2010

My program has a list of tabs that each contain a list of people.Clicking a person should edit their details, but instead, clicking a person throws an ActivityNotFoundException.

View 2 Replies View Related

Android :: Launching Intent From Class Outside An Activity

Jul 28, 2010

I've got two activities, one of them is called MyActivity. I want both of them to be able to use a function located in a class othat we may call MyClass. In MyClass, I try to use an intent to launch the activity AnotherActivity. Since the constructor takes a context as parameter, I simply tried to store a context from the activity in the constructor, and then use it when I try to create my intent.However, even thought none of the arguments are null (checked that with a simple if-statement), intent seems to be null and a NullPointerException is thrown. Why does it not work, and what can I do to solve the problem?
I'm quite new to Android and Java development, so please explain it as basic as you can.

View 2 Replies View Related

Android :: Launching Google Maps Directions Via Intent

Apr 18, 2010

My app needs to show Google Maps directions from A to B, but I don't want to put the Google Maps into my application - instead, I want to launch it using an Intent. Is this possible? If yes, how?

View 2 Replies View Related

Android :: Launching Intent Not Working On Saved Image File

Jun 2, 2010

First of all let me say that this questions is slightly connected to another question by me. Actually it was created because of that. I have the following code to write a bitmap downloaded from the net to a file in the sd card:

// Get image from url
URL u = new URL(url);
HttpGet httpRequest = new HttpGet(u.toURI());
HttpClient httpclient = new DefaultHttpClient();
HttpResponse response = (HttpResponse) httpclient.execute(httpRequest);
HttpEntity entity = response.getEntity();
BufferedHttpEntity bufHttpEntity = new BufferedHttpEntity(entity);
InputStream instream = bufHttpEntity.getContent();
Bitmap bmImg = BitmapFactory.decodeStream(instream);
instream.close();

// Write image to a file in sd card
File posterFile = new File(Environment.getExternalStorageDirectory().getAbsolutePath()+"/Android/data/com.myapp/files/image.jpg");
posterFile.createNewFile();
BufferedOutputStream out = new BufferedOutputStream(new FileOutputStream(posterFile));
Bitmap mutable = Bitmap.createScaledBitmap(bmImg,bmImg.getWidth(),bmImg.getHeight(),true);
mutable.compress(Bitmap.CompressFormat.JPEG, 100, out);
out.flush();
out.close();

// Launch default viewer for the file
Intent intent = new Intent();
intent.setAction(android.content.Intent.ACTION_VIEW);
intent.setDataAndType(Uri.parse(posterFile.getAbsolutePath()),"image/*");
((Activity) getContext()).startActivity(intent);

A few notes. I am creating the "mutable" bitmap after seeing someone using it and it seems to work better than without it. And I am using the parse method on the Uri class and not the fromFile because in my code I am calling these in different places and when I am creating the intent I have a string path instead of a file. Now for my problem. The file gets created. The intent launches a dialog asking me to select a viewer. I have 3 viewers installed. The Astro image viewer, the default media gallery (I have a milstone on 2.1 but on the milestone the 2.1 update did not include the 3d gallery so it's the old one) and the 3d gallery from the nexus one (I found the apk in the wild). Now when I launch the 3 viewers the following happen:

Astro image viewer: The activity launches but I see nothing but a black screen.
Media Gallery: I get an exception dialog shown "The application MediaGallery (process com.motorola.gallery) has stoppedunexpectedly. Please try again" with a force close option.
3D gallery: Everything works as it should.

When I try to simply open the file using the Astro file manager (browse to it and simply click) I get the same option dialog but this time things are different:
Astro image viewer: Everything works as it should.
Media Gallery: Everything works as it should.
3D gallery: The activity launches but I see nothing but a black screen.

As you can see everything is a complete mess. I have no idea why this happens but it happens like this every single time. It's not a random bug. Am I missing something when I am creating the intent? Or when I am creating the image file? As noted in the comment here is the part of interest in adb logcat. Also I should note that I changed the way I create the image file. Since I want to create a file that reflects an online file I simply download it instead of creating a Bitmap and then creating the file (this was done because at some point I needed the Bitmap but now I do it the other way around). The problems persist thought and are exactly the same:

I/ActivityManager(18852): Starting
activity: Intent {
act=android.intent.action.VIEW
dat=/sdcard/Android/data/com.myapp/files/image.jpg
typ=image/* flg=0x3800000
cmp=com.motorola.gallery/.ViewImage }
I/ActivityManager(18852): Start proc
com.motorola.gallery:ViewImage for
activity
com.motorola.gallery/.ViewImage:
pid=29187 uid=10017 gids={3003, 1015}
I/dalvikvm(29187): Debugger thread not
active, ignoring DDM send
(t=0x41504e4d l=38)
I/dalvikvm(29187): Debugger thread not
active, ignoring DDM send
(t=0x41504e4d l=64)
I/ActivityManager(18852): Process
com.handcent.nextsms (pid 29174) has died.
I/ViewImage(29187): In View Image
onCreate!
D/AndroidRuntime(29187): Shutting down VM
W/dalvikvm(29187): threadid=3: thread
exiting with uncaught exception
(group=0x4001b170)
E/AndroidRuntime(29187): Uncaught
handler: thread main exiting due to
uncaught exception
E/AndroidRuntime(29187):
java.lang.RuntimeException: Unable to
start activity
ComponentInfo{com.motorola.gallery/com.motorola.gallery.ViewImage}:
java.lang.NullPointerException
E/AndroidRuntime(29187): at
android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2496)
E/AndroidRuntime(29187): at
android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2512)
E/AndroidRuntime(29187): at
android.app.ActivityThread.access$2200(ActivityThread.java:119)
E/AndroidRuntime(29187): at
android.app.ActivityThread$H.handleMessage(ActivityThread.java:1863)
E/AndroidRuntime(29187): at
android.os.Handler.dispatchMessage(Handler.java:99)
E/AndroidRuntime(29187): at
android.os.Looper.loop(Looper.java:123)
E/AndroidRuntime(29187): at
android.app.ActivityThread.main(ActivityThread.java:4363)
E/AndroidRuntime(29187): at
java.lang.reflect.Method.invokeNative(Native
Method)
E/AndroidRuntime(29187): at
java.lang.reflect.Method.invoke(Method.java:521)
E/AndroidRuntime(29187): at
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860)
E/AndroidRuntime(29187): at
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
E/AndroidRuntime(29187): at
dalvik.system.NativeStart.main(Native Method)
E/AndroidRuntime(29187): Caused by:
java.lang.NullPointerException
E/AndroidRuntime(29187): at
com.motorola.gallery.ImageManager.allImages(ImageManager.java:5621)
E/AndroidRuntime(29187): at
com.motorola.gallery.ImageManager.getSingleImageListByUri(ImageManager.java:5515)
E/AndroidRuntime(29187): at
com.motorola.gallery.ViewImage.onCreate(ViewImage.java:1801)
E/AndroidRuntime(29187): at
android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
E/AndroidRuntime(29187): at
android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2459)
E/AndroidRuntime(29187): ... 11 more

View 3 Replies View Related

Android :: Pass In Bitmap As EXTRA_STREAM Parameter When Launching An Intent?

Jun 25, 2009

From the JavaDoc, the EXTRA_STREAM parameter when launching an intent needs to be an URI. How can I pass a Bitmap object which I get from launching a "android.provider.MediaStore.ACTION_IMAGE_CAPTURE" intent? code...

View 6 Replies View Related

Android :: Pausing VideoView When Launching A New Intent / Resume It To Starts Up Activity Again?

Jul 23, 2009

I have an activity that is showing a video and when the user clicks a button, a new activity is launched. When the video activity stops, I pause the video view. When the video activity starts up again, I try to resume the video view videoView.start(), however, the video starts over from the beginning. I'm thinking that the buffer must be lost somewhere, so I now try to capture the current position via videoView.getCurrentPosition(), however, this is always returning 0.

Anybody know how to resume video playback when an activity starts up again?

View 5 Replies View Related

Android :: Need A Camera App That Makes Magic Camera Not Suck?

Nov 15, 2009

Whats a camera app that will actually work and not take 30 seconds to take the picture after clicking to take it?

View 2 Replies View Related

Android :: For Launching A Camera From Appl - Which Action Requires?

Jan 29, 2009

For launching a camera from appl which action requires?

If start a camera from my appl and captured image, how should I pick-up (retrieve) that current image to my appl from camera provider. what is process for this(which Uri).

View 4 Replies View Related

Android :: Check Streetview Exists Before Launching Streetview Intent?

Oct 5, 2010

Launching a Streetview intent for a location doesn't guarantee that a Streetview exists for that location. If the Streetview doesn't exist, the user just sees a black screen that spins. Is there a way to programmatically check if it exists before launching the Streetview intent?

View 2 Replies View Related

Android :: Handle Existing Instance Root Activity Launching Root Activity From Intent Filter

Apr 3, 2010

I'm having difficulties handling multiple instances of my root (main) activity for my application. My app in question has an intent filter in place to launch my application when opening an email attatchment from the "Email" app. My problem is if I launch my application first through the the android applications screen and then launch my application via opening the Email attachment it creates two instances of my root activity. steps: Launch root activity A, press home Open email attachment, intent filter triggers launches root activity A Is it possible when opening the Email attachment that when the OS tries to launch my application it detects there is already an instance of it running and use that or remove/clear that instance?

View 1 Replies View Related

Android :: Camera Intent What's Safe To Use?

Dec 8, 2009

I'd like to let the user take a picture using the camera, then use it in my app. Ideally I could use the built-in camera app via an intent for this.is the only reliable option to use the 192x256 memory-only image supplied by the camera intent? The following seems to not work:

1) Asking the camera intent to write a 'full size' image to disk.

2) Writing your own camera app (issues on different devices etc).

The Facebook app seems to use the memory-only 192x256 option, probably because that's the only safe option. Anyone else have different opinions / experiences?

View 14 Replies View Related

Android :: Launch Camera App With An Intent?

Oct 7, 2010

I can't find any intent which opens the camera. The closest I've found is ACTION_CAMERA_BUTTON but that breaks if the phone has no hardware button for the camera.

View 3 Replies View Related

Android :: Starting Video Camera With Intent

Sep 20, 2010

I am writing a very small app that just opens the camera app ready for video. I am able to get my code to work on an Android 2.2 emulator, but it will not work on my device, Motorola Droid 1 stock 2.2 FRG22D. Any ideas where I went wrong on this code?

CODE:............

It appears ThorstenW is correct. I would upvote your answer if I had enough rep. You can see from the logcat that com.android.camera could not be found and throws a fatal exception. Logcat below.

CODE:...................

View 2 Replies View Related

Android :: Using Phone Camera Via Intent / Activity Never Returns?

Oct 18, 2010

I'm using the phone's camera in an Android app to take a photo. I'm using Intents to use the built-in camera application.It works fine and the camera is brought up. I can take a photo and the phone presents me with three options: Cancel, Retake, OK. The first two work, pressing cancel returns the user to the app, but pressing OK and nothing happens. Apparently onActivityResult isn't being called, and the camera just stays on the screen. Nothing in the debugger either.Running the app on a Nexus One with Android 2.2.1. Same problem on the emulator running Android 2.0.

View 1 Replies View Related

Android :: Taking Picture By Camera Correct Intent Action

Mar 3, 2009

I am trying to take picture by G1 camera.

I have tried almost everything i was able to find on the net about this topic. It seams there should be intent with action "android.media.action.IMAGE_CAPTURE" which really starts camera application and returns captured image. But captured image is scaled to 0.25 of original size. Another possibility I have found is to pass uri where to save captured image. I went through all available sources of camera application and it should work but does not.

For illustration, I am doing following in my example activity which creates new image, but after returning from camera, image is still empty:

CODE:..................

I am ready to write my own capturing application, but it is quite hard and I would like to reuse.

Do you know correct intent action name and extra name to pass to capture image?

View 4 Replies View Related

Android :: Correct Intent To Launch Gallery / Video Camera

Jul 28, 2009

My application has buttons to launch gallery and video camera apps but the below code only seems to work on phones with the standard Cupcake build:
// For Gallery Intent intent = new Intent(); intent.setClassName("com.android.camera", "com.android.camera.GalleryPicker");
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK); mContext.startActivity(intent);
// For Video Camera Intent intent = new Intent(); intent.setClassName("com.android.camera", "com.android.camera.VideoCamera"); intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK); mContext.startActivity(intent);

On rooted / non-cupcake phones, I get this error:
android.content.ActivityNotFoundException: Unable to find explicit activity class {com.android.camera/com.android.camera.VideoCamera};
have you declared this activity in your AndroidManifest.xml? at android.app.Instrumentation.checkStartActivityResult (Instrumentation.java:1480) at android.app.Instrumentation.execStartActivity(Instrumentation.java: 1454) at android.app.Activity.startActivityForResult(Activity.java:2656) at android.app.Activity.startActivity(Activity.java:2700)

View 3 Replies View Related

Android :: Reloading Our Activities State After Firing Intent To Camera

Aug 31, 2009

We have an Activity which has a form on it and we launch an Intent to take a picture.We've overridden onSaveInstanceState and onRestoreInstanceState to push the data from the view fields But, on the return from the CameraActivity, the onRestoreInstanceState method is never called. Should this behavior work when calling another Intent?

View 7 Replies View Related

Android :: Need To Push Intent To Default Camera Application To Make It Take Photo

Apr 28, 2010

I need to push an intent to default camera application to make it take a photo, save it and return an URI. Is there any way to do this?

View 2 Replies View Related

Camera - Intent Returns Null?

Mar 27, 2012

I have an android application which contains multiple activities. In one of them I'm using a button which will call the device camera :

Code:
public void onClick(View view) {
Intent photoIntent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);
startActivityForResult(photoIntent, IMAGE_CAPTURE);[code]....

The problem is that the intent data is null and the OnActivityResult method turns directly to the (resultCode == RESULT_CANCELED) and the application returns to the previous avtivity.How can I fix this issue and after calling the camera, the application returns to the current activity which contains an ImageView which will contains the picture taken?

View 1 Replies View Related

HTC Droid Eris :: Intent URI Code To Launch Camera Application?

May 2, 2010

im trying to find the code to launch the camera app and I cant figure it out.

View 3 Replies View Related

HTC Eris :: KaosFroyo - Camera Magic Hangs While Saving Snapshot

Jul 27, 2010

So I was aware of camera problems when flashing Kaos, but I'm having trouble getting Camera 360 or Camera Magic to work.

Camera 360 lags really bad before taking the photo, and Camera Magic hangs while "saving snapshot" or whatever it says after you snap a picture.

View 12 Replies View Related

HTC Hero :: Camera Not Working - Message The Application Camera Process Com.android.camera Has Stopped Unexpectedly Please Try Again

Dec 6, 2009

My camera stopped working. When I click my camera application I get the message "The application camera (process com.android.camera) has stopped unexpectedly. Please try again". It's just a blank screen?

View 3 Replies View Related

HTC Magic :: Playback Of Music Using Magic (rogers) Player?

Jul 28, 2009

playback of music using the htc magic (rogers) music player? I am getting some random blips of no audio when playing music. maybe a 1sec of no audio. Killed all tasks with taskiller and there is still the issue.

View 4 Replies View Related

HTC Magic : Difficulties Programming Hotmail To MAGIC Rogers

Feb 24, 2010

So for some reason after updating to SENSE UI for the Magic, I've had difficulties programming my hotmail into my phone. I'm not sure if its due to the firmware of if i'm simply doing something wrong. Here are my configuration settings (I'm using POP3):

Incoming Settings
Email address:
xyxyxy@hotmail.com

Username:
xyxyxy@hotmail.com

Password:
********* (i'm 100% sure i inputed it in correctly)

POP Server:
pop3.live.com

Security Type:
SSL

Server Port:
995

Outgoing Server Settings:
[checked] Login Required

Username:
xyxyxy@hotmail.com

Password:
*******

SMTP Server:
smtp.live.com

Security Type:
TLS

Server Port:
587

Does anyone know why it might not be working?

View 9 Replies View Related

HTC Magic : Putting Openhome Themes On An HTC MAGIC Rogers

Aug 18, 2009

Sadly, the Android Market in Canada does not have any paid apps. I was just wondering is there any way I can put themes onto my phone? I find that it really sucks that I can't use any of the dxtop themes or openhome themes in the market unless I actually have the app itself (which I cannot purchase).

View 3 Replies View Related

HTC Magic :: Magic Stuck In Safe Mode?

Dec 5, 2009

new to this site as never had any problems with my magic till today, my 2 year old to my horror threw it against the wall and the battery etc fell out, Fortunatly when i examined it there was no damage screen wasnt cracked or damaged or anything, however since ive turned it back on theres safe mode in transparetn writing at the bottom left of the screen and the touch screen doesnt work and every time i go into a process such as say contacts , i get the 'the process android.process.acore has stopped please try again everything works like i say i can go online but obviously without the use of the touch screen i cant type, nor can i send texts due to the lack of touchscreen so what can i do HELP PLEASE Or do i have to face facts and get in touch with my insurance ?

View 7 Replies View Related

HTC Magic :: Way To Root A 1.5 Rogers Htc Magic + Perfected SPL?

May 30, 2010

How To: Root the HTC Magic in One Click! | The Unlockr, is this a possible way to root a 1.5 rogers htc magic+ perfected SPL? i have the newest magic.

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved