Error in xml file while creating a project in black berry

房东的猫 提交于 2020-01-13 14:06:02

问题


I just created a new project in the eclipse and as soon as it was created, it is created with the error below

InvalidRegex:
Pattern value '([a-zA-Z_]{1,63}[\s-a-zA-Z_0-9.]{0,63}[;]?)*' is not a valid
regular expression.
The reported error was: ''-' is an invalid character range.
Write '\-'.' at column '{2}'.
BlackBerry_App_Descriptor.xml Unknown XML Problem.

This is the problem which we will get when there is jre7 in our system which is not supported by eclipse

What is the problem here? How can i rectify this? thank you


回答1:


Google shows this is related to Java 7. Check these two links: http://supportforums.blackberry.com/t5/Java-Development/problem-with-the-BlackBerry-App-Descriptor-xml-in-Eclipse-Plug/td-p/959029 and http://cdrussell.blogspot.com/2011/09/blackberry-eclipse-error-invalid-regex.html

The second one tells:

Turns out this could be caused by having Java JRE 7 installed on your machine. The BlackBerry plugin doesn't support this yet, Eclipse might be trying to use that.

The fix? You simply have to edit the eclipse.ini that will live in the same directory as your eclipse.exe that you use to start the IDE. Closing Eclipse and making a backup of eclipse.ini before you do this would be a good idea.

Find the line "openFile" and immediately after, add the following:

-vm C:/Program Files/Java/jre6/bin/javaw.exe [or wherever your jre6 directory might be]

Cross your fingers and restart Eclipse. Rebuild your projects.



来源:https://stackoverflow.com/questions/7729802/error-in-xml-file-while-creating-a-project-in-black-berry

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!