2013-02-12 28 views
0

我正在實現使用Android Plot jar文件示例的圖表應用程序。它顯示應用程序在Jar文件的com.androidplot.xy.XYPlot上運行。但是,而我在配置項目之後嘗試,它顯示了誤差,..androidplot xml文件中的錯誤

Could not find class 'com.androidplot.xy.XYPlot', referenced from method com.androidplot.xy.SimpleXYPlotActivity.onCreate 

幫我想想辦法......

我的XML代碼,..

<?xml version="1.0" encoding="utf-8"?> 
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 
      android:layout_width="fill_parent" 
      android:layout_height="fill_parent"> 
<com.androidplot.xy.XYPlot 
     android:id="@+id/mySimpleXYPlot" 
     android:layout_width="fill_parent" 
     android:layout_height="fill_parent" 
     android:layout_marginTop="10px" 
     android:layout_marginLeft="10px" 
     android:layout_marginRight="10px" 
     title="A Simple XYPlot Example"/> 
</LinearLayout> 

回答

0

通常這意味着您要麼在項目的/ libs目錄中沒有androidplot jar文件,要麼如果您正在使用像IntelliJ或Eclipse一樣的IDE和ADT,則您並未明確將該jar添加到您的類路徑中。

此外,如果你正在使用Androidplot 0.5.1或更高版本,你需要改變這一行:

title="A Simple XYPlot Example" 

androidPlot.title="A Simple XYPlot Example"