Hi,
I have below code in my module’s client hook:
public void startup(ClientContext context, LicenseState activationState) throws Exception {
super.startup(context, activationState);
VisionClientInterface vision = (VisionClientInterface)context.getModule(VisionClientInterface.VISION_MODULE_ID);
if(vision != null)
{
vision.getGuiUtil();
}
}
When I install the module and start the client, I get following error
java.lang.NullPointerException: null
at com.inductiveautomation.factorypmi.application.runtime.ClientContextImpl.getGuiUtil(ClientContextImpl.java:438)
at com.vaspsolutions.mymodule.client.MyModuleClientHook.startup(MyModuleClientHook.java:30)
at com.inductiveautomation.factorypmi.application.runtime.ClientContextImpl$LoadedModule.startup(ClientContextImpl.java:328)
at com.inductiveautomation.factorypmi.application.runtime.ClientContextImpl.startup(ClientContextImpl.java:373)
at com.inductiveautomation.factorypmi.application.runtime.ClientPanel.startupApp(ClientPanel.java:710)
at com.inductiveautomation.factorypmi.application.runtime.ClientPanel$LoginAction$LoginTask.run(ClientPanel.java:547)
at java.lang.Thread.run(Unknown Source)
Tried this with Ignition SDK versions 7.9.3, 7.9.4 and 7.9.5-SNAPSHOT
Ignition versions 7.9.5 and 7.9.7.
Is this an issue with API or am I missing something ?
getGUIUtil when called from VisionDesignerInterface in the designer hook works correctly.
Request to please help.