Import javax.xml.transform cannot be resolved

I am trying to write some xml generated by my Android application to a file and I am trying to use javax.xml.transform for this. The only problem is that javax.xml.transform was not found by eclipse.

The only parameters that appear are javax.xml and javax.xml.parsers. Does anyone know what might happen?

Edit: just fyi I have installed Java JDK 6 update 22.

+4
source share
3 answers

I just found out what to do. If you right-click on any project you are working on, and go to the properties. Then, on the Libraries tab, click Add Libraries and add the JRE System Library, and then add new imports that you can use, including javax.xml.transform.

It took forever to find out that a simple thing = P. But now I know.

+5
source

javax.xml.transform is only available at API level 8 +.

even if you add JRE System Libraries, this will be a runtime error.

+3
source

Android-, Android Eclipse, - classpath ( ), , , , Android.

+1

Source: https://habr.com/ru/post/1776111/


All Articles