blackberry

Json Send/Post error in blackberry

…衆ロ難τιáo~ 提交于 2019-12-12 02:55:07
问题 I want to send JSON request through HTTPConnection but i am getting error when i am trying to get the response code. Here is my code... public void sendrequest(String url)throws IOException, JSONException { JSONObject postObject = new JSONObject(); postObject.put("method", method); postObject.put("params", Parameters); HttpConnection c = (HttpConnection)Connector.open(url); c.setRequestMethod(HttpConnection.POST); c.setRequestProperty("Content-Type", "application/json;charset=UTF-8"); c

Ant build for blackberry when startup tier is 6

天涯浪子 提交于 2019-12-12 02:44:09
问题 I have two blackberry library applications and one cldc application. I want to compile a build.xml integrating all this. cldc and library 2 refers to library 1. library 1 has startup tier as 6 which means install during device start. library 2 can be either 7 or 6. how to achieve the ota build which does have all these functionalities? 回答1: Consider BB Ant Tools JDP element of RAPC task allows setting startup tier for the compiling cod file. 来源: https://stackoverflow.com/questions/6978504/ant

set text(number) to Edit Field through its setchangelistener

↘锁芯ラ 提交于 2019-12-12 02:43:21
问题 Hi I want to accept number in edit field up to two decimal.So I am setting listener to it Then I am checking whether number is two decimal or more and if it is more than two decimal then i am truncating the number and again trying to set the truncated number.But it showing 104 error at this place interestRate.setText(text).My code is interestRate=new EditField(); interestRate.setChangeListener(new FieldChangeListener() { public void fieldChanged(Field field, int context) { String text

BlackBerry to Code Home Screen As described below

♀尐吖头ヾ 提交于 2019-12-12 02:37:01
问题 Hi Guys please see this is the Home screen i want to make in blackberry, i have tried putting in the vertical and horizontal field manager but i cant embed all together which give me result screen as mentioned above.. Please note the button are the Image button i have provided.. i want the structure code if any one can help me out .. Vertical Manager(main) Horizontal Manager (for Two Buttons) horizontal Manager (for Three Buttons) Bitmap Field (for Image) Add all three in Vertical Manager and

how to get current cpu usage and memory usage in blackberry?

拜拜、爱过 提交于 2019-12-12 02:22:54
问题 I am making an application in blackberry, Here i want to know the current cpu usage and memory usage. How to find that? 回答1: Refer this link Memory Memory.getRAMStats().getFree(); Memory.getRAMStats().getAllocated()); 来源: https://stackoverflow.com/questions/10226263/how-to-get-current-cpu-usage-and-memory-usage-in-blackberry

Does porting Android application to BB 10 causes performance issues?

半腔热情 提交于 2019-12-12 02:16:02
问题 I am very new to BlackBerry 10 development. Reading some of the documents I could understand that it is possible to port Android applications to BB 10. In fact it is the only way one can develop apps for BB 10 using JAVA language. I really wonder porting the apps will ever cause any performance issues in BB 10. My client is very particular about the performance of the application which we are developing. Can any of the experts here tell me whether there is a chance that the ported application

Load URL into webview and hide address bar

淺唱寂寞╮ 提交于 2019-12-12 02:12:58
问题 As i am newbie in BlackBerry development, i don't know what should i implement for the below problem: I want to load web page inside the webview (Navigation should be within application) and hide the URL address bar of the webview.) I know the solution we do in Android as to make webViewClient and load the same inside the WebView inside the Android. But i don't know about the exact solution for the BlackBerry. One more thing, i have gone through BrowserField demo but i am not able to load

blackberry parameterised are only available if source level 1.5

匆匆过客 提交于 2019-12-12 02:12:05
问题 When i user vector object in my blackberry app like below Vector<Object> vector = new Vector<Object>(); i am getting compiler error as blackberry parameterised are only available if source level 1.5 why is this error ? 回答1: BlackBerry is based on JavaME which is currently limited to Java 1.3 syntax. Thus, since generics were added in Java 5 (1.5), you are out of luck, unfortunately. 回答2: Classes compiled for the BlackBerry must use version 1.3 of Java, which precludes things like generics and

blackberry server connection problem

别来无恙 提交于 2019-12-12 01:53:56
问题 I want to send data to the server by using URLEncodedPost Class. I am getting error while i am trying to call the POST method. so if anybody have any idea about this method then give me some hint about it. enter code here 回答1: You are not posted any code to know which error you are getting any way, the following code is an example of Http Post method HttpConnection connection = (HttpConnection) Connector.open("url", Connector.READ_WRITE); connection.setRequestMethod(HttpConnection.POST);

blackberry HttpConnection.GET

亡梦爱人 提交于 2019-12-12 01:48:45
问题 URL: http://monSite/GET.asp we must authenticate before getting the result. I want to send the login and password with HttpConn.setRequestMethod (HttpConnection.POST) and retrieve the XML file with HttpConn.setRequestMethod (HttpConnection.GET) with the same HTTP Client. conn = (HttpConnection) new ConnectionFactory().getConnection(_url).getConnection(); URLEncodedPostData postData = null; postData = new URLEncodedPostData("UTF-8", false); postData.append("userName",_username); postData