wood burning stoves 2.0*
The moose likes Other Open Source Projects and the fly likes Solution for the error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Products » Other Open Source Projects
Bookmark "Solution for the error "error could not access the package manager. is the system running"" Watch "Solution for the error "error could not access the package manager. is the system running"" New topic
Author

Solution for the error "error could not access the package manager. is the system running"

rajesh rasu
Greenhorn

Joined: Sep 20, 2012
Posts: 3
When i install the android application in the emulator through ant script,the emulator is launched successfully.But i got error like "error could not access the package manager. is the system running" before installation of the application.Please tell solution for this.

My Ant code is below.

<?xml version="1.0" encoding="UTF-8"?>

<project name="myproject">

<target name="create_avd_device">
<exec executable="D:/android-sdk/tools/android.bat">
<arg value="create"/>
<arg value="avd"/>
<arg value="--target"/>
<arg value="2"/>
<arg value="--name"/>
<arg value="rt5"/>
</exec>
</target>


<target name="start.emulator" depends="create_avd_device" >
<exec executable="D:/android-sdk/tools/emulator.exe" timeout="30000">
<arg value="-avd"/>
<arg value="rt5"/>
</exec>
</target>


<target name="list_device">
<echo message="list of device"/>
<exec executable="D:/android-sdk/platform-tools/adb.exe">
<arg value="devices"/>

</exec>
</target>

<echo message="Build it and set it up for android" />
<echo message="launch of app"/>
<target name="push_tests_to_device" depends="list_device">

<exec executable="D:/android-sdk/platform-tools/adb.exe">
<arg value="install"/>
<arg value="-r"/>
<arg value="D:\AnBEmail.apk"/>
</exec>
</target>


</project>
mr Morena
Greenhorn

Joined: Jan 15, 2008
Posts: 6
rajesh rasu wrote:When i install the android application in the emulator through ant script,the emulator is launched successfully.But i got error like "error could not access the package manager. is the system running" before installation of the application.Please tell solution for this.

My Ant code is below.

<?xml version="1.0" encoding="UTF-8"?>

<project name="myproject">

<target name="create_avd_device">
<exec executable="D:/android-sdk/tools/android.bat">
<arg value="create"/>
<arg value="avd"/>
<arg value="--target"/>
<arg value="2"/>
<arg value="--name"/>
<arg value="rt5"/>
</exec>
</target>


<target name="start.emulator" depends="create_avd_device" >
<exec executable="D:/android-sdk/tools/emulator.exe" timeout="30000">
<arg value="-avd"/>
<arg value="rt5"/>
</exec>
</target>


<target name="list_device">
<echo message="list of device"/>
<exec executable="D:/android-sdk/platform-tools/adb.exe">
<arg value="devices"/>

</exec>
</target>

<echo message="Build it and set it up for android" />
<echo message="launch of app"/>
<target name="push_tests_to_device" depends="list_device">

<exec executable="D:/android-sdk/platform-tools/adb.exe">
<arg value="install"/>
<arg value="-r"/>
<arg value="D:\AnBEmail.apk"/>
</exec>
</target>


</project>


Dear,

Just wait until emulator be loaded completely, once it finished then you could simply run your application


SCJP 6.0
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Solution for the error "error could not access the package manager. is the system running"
 
Similar Threads
Cannot find platform-tools folder and adb.exe inside it
ANT & JAXB: add Extension and make generated classes Seriazable
about wsgen with ant
Missing adb.exe
query regarding Ant 'Exec' task