Hi Eswar,
This error is neither machine nor application specific.
Probably your executeCommand() method may be giving some error if your Query in the applet is not executing properly.
Few things:
1. What version of JRE are you using?
2. Did you try putting an alert inside your IF statement to check whether the applet is executed without error or not?
Best Regards,
Anuj