It would be great if you can provide more specific error like, what is the error you are getting while running / compiling the program, etc.
I am assuming you want to compile your .java files compatible to older versions. You can use "-source" switch of javac for that.
Code:
javac -source 1.4 MyProgam.java
Above line will treat MyProgram.java as Java 1.4 compatible source and will produce binary which is compatible with JRE 1.4
I hope this helps.