> where do I have to use this command?
Did you?
a) read the API for a description of what the command does
b) search the forum using "setlocation" as the keyword to see examples of how it should be used. Of course if you search the Swing forum, which is where Swing related questions should be posted, you would have a better chance of finding posted examples.