java-me

How to do Parsing in j2me(java)

痴心易碎 提交于 2019-12-24 15:06:53
问题 i want to extract the iframe tag "src" value from the below url http://www.teluguone.com/videos/single/comedy/Comedy-Express-464---Back-to-Back---Comedy-Scenes-14727.html iframe width="640" height="380" src="http://www.youtube.com/embed/XJDw2T1nGJQ"frameborder="0" allowfullscreen/iframe How can i achieve it in j2me?htmlparser ,Jericho ,Jsoup parser are not supported in j2me 回答1: Assuming you already have the html source stored in a String variable called htmlPage. int iFrameIndex = htmlPage

Why does my J2ME Bluetooth code hangs after an incoming RFCOMM connection?

纵然是瞬间 提交于 2019-12-24 13:44:17
问题 All I want to do is send "hello" to the first incoming RFCOMM Bluetooth connection and then exit. My code works on Nokia N73 but not on more modern devices like Nokia E52. In Nokia E52, the application hangs just after: streamConnectionNotifier.acceptAndOpen(); Here is the code: All the code is inside the run() method of my Thread: public class BTTest extends Thread { public void run() { ... } } I first set my bluetooth device discoverable: try { LocalDevice localDevice = LocalDevice

use graphics.drawText(String, x, y) to draw a string on several lines

浪子不回头ぞ 提交于 2019-12-24 12:51:32
问题 I am making a custom Field representing an image and a label near it. I am drawing the image by graphics.drawBitmap(...) Nw for the text, I am using graphics.drawText(String, x, y); but if the text it bigger than the display, it doesn't return to the line. I tried to add \n but that didn't solve the problem. How can I draw a text that can expand on several lines? Thanks, 回答1: I found a solution to the problem. You can find it below for those who are interested in this question: public void

LWUIT Command buttons not always visible

百般思念 提交于 2019-12-24 10:59:22
问题 I've written a LWUIT app but every few times I run it in the builtin Netbeans J2ME emulator or the Nokia Series 40 emulator, the command buttons for the main page do not show up. If I hit the softkey for the second command to go the the help screen, then go back, the commands are visible. I setup my commands exactly according to the tutorial, with these few lines of code: Command exitCommand = new Command("Exit"); f.addCommand(exitCommand); Command settingsCommand = new Command("Help/About");

how can I create an application for mobile phone with .JAR extension? [closed]

前提是你 提交于 2019-12-24 10:45:04
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 4 years ago . I Want to create a photo dictionary with .jar extension for mobile phones,what is the right tool or language for this purpose ? 回答1: I suspect that you would want to write a so called MIDlet using Java ME. The proper tools include The Java SDK Eclipse together with a proper plugin such as EclipseME (or another

Which Eclipse download for developing for Java ME

不问归期 提交于 2019-12-24 10:44:17
问题 I am new in Java ME. I need to download J2ME with Eclipse and follow the guide from the j4me Wiki. The problem is when I jump to the official Eclipse site, I see approximately 12 options. Which one do I need? 回答1: Download the Eclipse pulsar. Its mobile platform version of eclipse. Then download the sun java toolkit or Java ME SDK and install it. After that you need to integrate with that SDK with Eclipse. Just follow the following step. window -> preferences -> Java ME -> Device Management -

RIM blackberry Record 3GP video

荒凉一梦 提交于 2019-12-24 10:39:28
问题 I am writing an application that can record a 3GP video. I have tried both MMAPI and Invoke API. But have following issues. Using MMAPI: When I record to stream, It records video in RIMM streaming format. when I try to play this video player gives error "Unsupported media format." When I record to a file. It will create a file of size 0. Using Invoke API: In MMS mode it does not allow to record a video more than 30 seconds. In Normal mode size of the file is very large. Once I invoke camera

Command in LWUIT

本秂侑毒 提交于 2019-12-24 10:03:10
问题 How to add more than 2 command in a single row in at the Footer in lwuit Form ,suppose I want to add Back,Select,and Exit Command in a single row,how can I do that? Help with some example. 回答1: Use Display.getInstance().setThirdSoftButton(true); for showing three softbutton's. 回答2: You can also write your_Form.setDefaultCommand(the_command_in_the_middle); 回答3: I noticed that setting commandBehaviour to SoftKey in the resource editor makes all your commands align on one side, typical

Shows “NoClassDefinationFound for java/util/Comparator” though added jre to build path

穿精又带淫゛_ 提交于 2019-12-24 08:47:51
问题 I am using j2me + S60 symbian SDK on win7, initially i've installed with jdk6 and IDE(Eclipse) then i install SDK S60. But as you know that j2me supports only 1.3 compliance level for projects so, i downloaded jdk1.3.1_28 and install it added it to preference -> Java -> installJREs. So now it will added to build path of new project, but it's not happening if i use Comparator (java.util.Comparator) class it ask me to add 1.3 jre to build path. I did it but still showing error that "

JavaME Nokia Maps API: how to display additional info on marker click?

喜你入骨 提交于 2019-12-24 08:22:42
问题 I need to display an additional info for a marker when it's clicked. I expected to find a way how to display a popup window (like a tooltip) with a short description on marker click, but failed. I use MapMarker class for my markers because I need custom icons. The MapMarker and MapStandardMarker classes do not have the functionality I need. As I understand, I need something like Android MapView Balloons 回答1: I've solved the problem. I use the popup dialog similar to the one implemented in