You don't need to specify "file://" new File("/sdcard/DCIM/Opi.apk")
-- Jack Ha Open Source Development Center ・T・ ・ ・Mobile・ stick together The coverage you need at the price you want The views, opinions and statements in this email are those of the author solely in their individual capacity, and do not necessarily represent those of T-Mobile USA, Inc. On Sep 10, 1:00 am, Mahsa M <mahsa.movah...@gmail.com> wrote: > Hi all > I have a code to install one apk file in my sdcard, > > Intent intent = new Intent(Intent.ACTION_VIEW); > Log.e("test","test"); > intent.setDataAndType(Uri.fromFile(new > File("file:///sdcard/DCIM/Opi.apk")), > "application/vnd.android.package-archive"); > Log.e("test2","test2"); > startActivity(intent); > > but I got the error on emulator that say parser can not pars your data,I was > wondering if any body can help me, > > thanks, > Mahsa --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Beginners" group. To post to this group, send email to android-beginners@googlegroups.com To unsubscribe from this group, send email to android-beginners-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-beginners?hl=en -~----------~----~----~----~------~----~------~--~---