GUIKit runtime error occurred :java.lang.NullPointerException

*To*: mathgroup at smc.vnet.net*Subject*: [mg109372] GUIKit runtime error occurred :java.lang.NullPointerException*From*: Andrey <andrey.siver at gmail.com>*Date*: Fri, 23 Apr 2010 03:51:23 -0400 (EDT)

Hello, I have a module which uses GUIKit to build some user interface in Mathematica. It works OK from Mathematica frontend but it does not work in batch mode: "f:/program files/wolfram research/mathematica/7.0/math.exe" -initfile ".../path/gui-module.m" -noprompt Get out the exception: GUIRun::err: The following GUIKit runtime error occurred :java.lang.NullPointerException. GUIRunModal::nvalid: The GUI definition contains invalid content. What may be the reason? Regards, -Andrey