title: NoClassDefFoundError when running Monkey runner script
body: <p>I am running first time <strong>monkey runner script</strong> in my application but i got this following error:</p>
  
  <pre><code>D:\android softwares\AndroidSDK\tools&gt;monkeyrunner.bat test1.py
  Exception in thread "main" java.lang.NoClassDefFoundError: com/android/chimpchat
  /ChimpChat
          at com.android.monkeyrunner.MonkeyRunnerStarter.&lt;init&gt;(MonkeyRunnerStart
  er.java:60)
          at com.android.monkeyrunner.MonkeyRunnerStarter.main(MonkeyRunnerStarter
  .java:188)
  Caused by: java.lang.ClassNotFoundException: com.android.chimpchat.ChimpChat
          at java.net.URLClassLoader$1.run(Unknown Source)
          at java.security.AccessController.doPrivileged(Native Method)
          at java.net.URLClassLoader.findClass(Unknown Source)
          at sun.misc.Launcher$ExtClassLoader.findClass(Unknown Source)
          at java.lang.ClassLoader.loadClass(Unknown Source)
          at java.lang.ClassLoader.loadClass(Unknown Source)
          at java.lang.ClassLoader.loadClassInternal(Unknown Source)
          ... 2 more
  </code></pre>
  
  <p>But i am unable to sort out this issue. Please help...</p>
  
  <p><strong>Here is my script:</strong></p>
  
  <pre><code>from com.android.monkeyrunner import MonkeyRunner, MonkeyDevice
  
  device = MonkeyRunner.waitForConnection()
  
  device.installPackage('myfile.apk')
  
  package = 'com.example.android.myapplication'
  
  runComponent = 'com.example.android.myapplication/.Home'
  
  device.startActivity(component=runComponent )
  
  device.press('KEYCODE_MENU', MonkeyDevice.DOWN_AND_UP)
  
  result = device.takeSnapshot()
  
  result.writeToFile('/shot1.png','png')
  </code></pre>
  
  <p>Thanks,
  Ram.</p>