I get an error while using import javax.microedition.lcdui.*;
package javax.microedition.lcdui.* does not exist.
But the line import javax.microedition.midlet.MIDlet;
does not give any error.
Imoprt lcdui jar file in your application library. You can download this jar file from here. Download Jar file
Related
I am learning how to use JavaMail. (i have se11)
I downloaded javax.mail.jar,
put it under C:\Java\jdk , and extract it.
I followed the instruction, set CLASSPATH = C:\Java\jdk\javax.mail.jar ;
and I add the javax.mail.jar to the eclispe Referenced Library.
However, when i try to import javax.mail.* , it says the import can not be resolved.
I open the extracted folder, and it contains only .class files.
I tried to open the javax.mail.Session file from eclipse file explorer, but it said:
"The JAR file C:\Java\jdk\bin\javax.mail.jar has no source attachment."
what should I do in order to import the javax.mail.* ?
I am very frustrated, please help!
No matter how you run your program, to just use the classes in a jar you need to have the jar file in your classpath. If you run from the command line you can do this:
java -cp C:\Java\jdk\javax.mail.jar my.fully.qualified.classname
If you're in Eclipse then:
Import the jar file into your Java project. Use the File-->Import... action.
Select your java project and select Build Path --> Configure Build Path...
Select Java Build Path on the left
Select the Libraries tab and the Add Jars... button on the right
Navigate to and select the jar you you imported above
Click OK
The classes in the jar file are now available for use in your code.
the idea cannot resolve java.sql.* symbole,below is i find problem.i install jdk with 1.8.0_181.
i have already tried using below actions. file->invalidate cache /restart,But the problem still exists
it is said the unused import
the rt.jar package in idea explorer,the jdk path is C:\Program Files\Java\jdk1.8.0_181\jre\lib
the rt.jar package in winrar explorer, the jdk path is C:\Program Files\Java\jdk1.8.0_181\jre\lib
You need to add mysql dependency to your project. If you are using the maven project, gradle ,sbt use this link and add it into your project.
https://mvnrepository.com/artifact/mysql/mysql-connector-java/8.0.12
If you are not using any of this above download mysql-connector-java jar manually and add it in class path.
you can download jar from here https://www.mysql.com/products/connector/
I am trying to build openfire from the source code. getting compile time error. below classes not found.
import com.install4j.api.Context;
import com.install4j.api.ProgressInterface;
import com.install4j.api.UninstallAction;
from where we can download these jar files. tried
https://mvnrepository.com/artifact/com.install4j?sort=newest
all the jar file still does not work. Any idea.
Thanks
Mohsin
The install4j artifacts are available from the repository
https://maven.ej-technologies.com/repository
See https://www.ej-technologies.com/resources/install4j/help/api for more information.
I want to make a Selenium project with Eclipse. I have added the reference to the selenium-server-standalone-3.4.0.jar file but I cannot import the package com.thoughtworks so the following lines produce an error:
import com.thoughtworks.selenium.DefaultSelenium;
import com.thoughtworks.selenium.Selenium;
Selenium RC has become obsolete in the newer selenium versions.
Download Selenium server 2.43 jar file, include it in your project and your issue will be gone.
Yesterday I was working in my project. Today when I opened eclipse there is an error:
The import org.apache.camel cannot be resolved in .java file.
I tried to add .jar file then I got another error:
The import org.springframework cannot be resolved.
Then I tried to add this .jar and I got another error. What happened overnight?
Note: There is maven integration with my eclipse.
you need to specify versions for each library defined in pom.xml file.