嗨我工作的的PhoneGap
通过命令行界面。
Hi I am working on PhoneGap
through a command line interface.
我能够在Windows 7中创建一个项目,并运行在命令提示符下一个Android模拟器。
I am able to create a project, and run an android emulator from the command prompt in Windows 7.
由于我进口,复制项目到我的Eclipse工作区中,它显示在一个延伸 CordovaActivity
的主类的一些错误。
Since I imported and copied the project into my workspace in eclipse, it is showing some errors in the main class which extends CordovaActivity
.
该错误是:
"CordovaActivity cannot be resolved to a type".
我应该怎么办?
对于那些不希望从命令行使用它谁只是增加一个外部库科尔多瓦,Android项目来解决此问题。
For those who don't want to use it from command line just add an external library cordova-android project to resolve this issue.
请按照下列步骤操作:
从这里下载1-科尔多瓦的Android拉链 https://github.com/apache/cordova-android 。
1- Download Cordova android zip from here https://github.com/apache/cordova-android.
2 - 解压缩zip您的PC上的任何地方。进入框架文件夹中。
2- Extract zip anywhere on your PC. Go inside framework folder.
3导入该提取的zip文件夹/框架在Eclipse作为一个现有的项目,这将导致在工作区科尔多瓦项目(库)。
3- Import this extracted zip folder/framework in your eclipse as an existing project which will result in Cordova project(library) in your workspace.
4-现在,右键点击你的应用项目 - >属性 - > Android系统。在库部分中选择添加,然后选择科尔多瓦项目(库)。
4- Now right click on your app project -> Properties -> Android. In the Library section choose 'Add' and select Cordova project(library).
5最后补充进口org.apache.cordova;使用扩展CordovaActivity。
5- Finally add import org.apache.cordova; to use extend CordovaActivity.
上一篇:BroadcatReceiver的manifest.xml中宣称没有收到LocalBroadcastManager意图意图、manifest、BroadcatReceiver、LocalBroadca
下一篇:什么是组件的.NET 2.0 Microsoft.Web.Service3在.NET 4.0中?组件、NET、Microsoft、Web