Care to tell us the errors you're receiving?
Took a glance at it, oh where do I even begin.
What's this?
sortProductName( productName );
Unless its returning a value and assigning it to something, you have to put it inside a method or constructor.
This, too, can not be outside a method. It also never performs any action because of the semicolon after the declaration.
for ( int counter = 0 ; counter < productNum.length; counter++ );
And just after that line, you put the closing bracket for hte class, making the following methods belong to nothing.
Actually, you have a ton of problems with your curly brackets. Many are out of place, some appear just to be the wrong direction of bracket, and some are just plain missing. Go through your whole program, indent everything evenly, and look at those brackets carefully.
Also, before you can add "this" as an ActionListener for the buttons, the class must implement the ActionListener interface.
You're also trying to declare "button" multiple times. Plus you're calling classes that do not exist.
JButton1, JButton2, JButton3
It should be:
JButton button1 = new JButton("First");
JButton button2 = new JButton("Next");
JButton button3 = new JButton("Previous");
By the way, why are you making all your methods static anyway?
Also, put the ImageTest class in a separate file.