How to use MigLayout in IntelliJ? - java

I have no idea how to get MigLayout to work in IntelliJ (I'm sort of a noob at IntelliJ). I am currently using the 2017.3.5 community edition.
I've downloaded the jar file, but I can't seem to import it correctly.
I have import net.miginfocom.swing.MigLayout; at the top of my main file, but
when I try to compile my code, I keep getting an error
Error:(40, 30) java: cannot access net.miginfocom.layout.LC
class file for net.miginfocom.layout.LC not found
Any idea what I'm doing wrong?

Also include the core lib. You can get it here

Sorry for late. But it will help somebody.
IntelliJ Idea will allow to download a maven dependency as a Jar file under the lib folder.

Try:
File->Project Structure->select Modules on the left-> choose the Dependencies tab-> find the + either at ther right or bottom-> add the .jar

Related

My spring-boot program doesn't have the JavaBuilder in the Properties

I loaded a project on Spring-tool Suite but I realized that it does not correct the errors. Going to see Properties I realized that all the parameters related to the JavaBuilder that I have in the other loaded projects were missing. I think it's a Jdk problem, but I don't know how to set everything up or how to reset the project in order to have the error corrected.
thanks to anyone who can help me!
I think you need to delete the .metadata folder in your workspace.
The problem was Spring-Tool itself which had a bug where it didn't show any kind of error. There are two ways to get around the problem: delete the project from Spring-boot, delete the Workspace and reload everything. In case it is also recommended to download Spring-boot tool Suite again. In the second case it could be an error importing the project, try to import it to Intellij or another IDEE and see if you have the same problems. If you have the same problems it is a problem of loading the java libraries. To solve it you should open another project where you have no problems and once opened, go to FILE-> NEW-> IMPORT PROJECT and import your project.

the import org.eclipse(.emf) cant' be resolved

I try to test the EMF API and work with EPackage, EClass,...
To do this I need to import org.eclipse.emf.Ecore if I am not mistaken.
The problem is that I get this org.eclipse cant' be resolved problem.
Itried many solution including installing EMFplugging, plugin devellopement environment, downloading and adding org.eclipse.emf jars to my build path (downloaded at http://www.java2s.com/Code/Jar/o/Downloadorgeclipseemf260v201201231045jar.htm)
Do you know any tip to have an easy and quick solution (maybe an eclipse release or the correct jar file)?
Thanks
Use a package with (or install) EMF like https://www.eclipse.org/downloads/packages/release/2019-06/r/eclipse-modeling-tools and make sure to create "plug-in" projects where in the MANIFEST, tab 'dependencies' you have the plug-in containing e.g. org.eclipse.emf.ecore in there.

Twilio API issue

Hello stackoverflow,
This might be a really easy question but I am having issues with building a basic sms reply application in java. I googled around and couldn't find a solution for my problem. The issue occurs when I do the following imports:
import com.twilio.sdk.verbs.TwiMLResponse;
import com.twilio.sdk.verbs.TwiMLException;
import com.twilio.sdk.verbs.Message;
Eclipse throws an error when I try calling and implementing the Message class sayingThe import com.twilio.sdk.verbs.Message cannot be resolved . I have no issues with the other classes, just the Message class. And I have used Maven to compile the project.
Anybody have any solutions and/or solutions for this issue?
You need to specify external libraries in the Build Path.
In Eclipse right click on your project > Build Path > Configure Build Path > Libraries > Add JARs (or "Add External JARs" if you didn't copy it into your project folder).
If it still doesn't work there might be dependencies you are missing, so you need those as well. To save the headache you could also use Maven to download them automatically.
I was using the wrong Twilio SDK version in my maven dependency. I was using 3.3.15 and I updated it to 4.4.2 and it solved my issue. Thanks for all the comments and replies

Eclipse missing imports (javax.media.* and com.sun.media.*)

I have this old java applet that i need to debug, yet i have some problems with import.
The import javax.media.* cannot be resolved.
The import com.sun.media.* cannot be resolved
After some research i tried adding this external libs to the project - with no success.
sun-jai_codec.jar from http://www.java2s.com/Code/Jar/s/Downloadsunjaicodecjar.htm
installed JMF2.1.1e and added the jmf.jar.
I had no luck with this... so im asking some one for a little help!
Just build the path of your project again. Right click on the project and then select build path--->configure build path--->java build path---->libraries
select all jars and then remove and then add all jars including the jars of your project.
then click ok. then go to order and export and click all the options. then click ok.
Sheez .. this was stupid.
Its a big MESS with this old classes/jar files.
It turned out i had the wrong ones...
Found them here (links in the answer):
Where can I download Jai and Jai-imageio?

How do you Add a Library folder to eclipse?

Okay, I know this is a Noob question but I cant see to get it figured out! I'm trying to get the Android-ViewPageIndicater library imported to Eclipse, but it doesn't have a LIB file to add, and I cant figure out how to import the library folder because Eclipse says theres no project in it! Does anyone know how to do this? Thanks
I was facing the same issue. The solution is
1>Create a new android project with existing source (Select that library folder)
2> Mark that project as library
Later you can use this library for other projects

Categories

Resources