This module describes some of the common problems users encounter when they compile and run HLU applications.
The HLU APIs were designed so that a descriptive error message is generated when a problem is encountered. The Error class can be used to trap and print these messages. However, there are some cases where errors can occur which go unreported. This module will point out such cases as we discover them.
Also, note that the form of the compiler error messages listed in this module are system- and compiler-dependent.
You may have spelled the resource name incorrectly, spelled an object id incorrectly, or formed an illegal object pathname. Errors of these kinds in a resource file are not reported. To see if the problem is of this kind, set the resource in question directly in your HLU code as shown in Three ways to set resources. Compile and run your code using nhlcc or nhlf77 and watch for an error message. If there is no error message and the plot now reflects the change in the resource value, then there is indeed a pathname error in defining that resource in your resource file. To determine if the error is in the pathname, default the resource to apply to all objects in its hierarchy using the wild card character as in:
*resourcename : resource value
cfe: Error: xy04c.c, line 109: 'NhlNxyCoordData' undefined; reoccurrences will not be reported. NhlRLSetInteger(rlist,NhlNxyCoordData,dataid); --------------------------^ cfe: Error: xy04c.c, line 110: 'NhlxyPlotClass' undefined; reoccurrences will not be reported. NhlCreate(&plotid,"xyPlot",NhlxyPlotClass,xworkid,rlist); -------------------------------^
#include <ncarg/hlu/XyPlot.h>was omitted. This is the header file needed by the XyPlot object.
fatal:nhlfcreate:Invalid Class Function fatal:NhlDraw: Invalid plot ID: -4
external nhlfxyplotclassfrom your Fortran program.
Likewise, if you omit
external nhlfxworkstationclassyou will get errors like:
fatal:nhlfcreate:Invalid Class Function fatal:_NhlCreate:Invalid Parent id #-4 fatal:NhlDraw: Invalid plot ID: 0 fatal:Unable to update Workstation with PID#-4 fatal:Unable to clear Workstation with PID#-4 fatal:Unable to Destroy (Bad PID#-4)Consulting Contacts:Omitting
external nhlfappclasswill result in:
fatal:nhlfcreate:Invalid Class Function fatal:_NhlCreate:Unable to access "default" App object fatal:_NhlCreate:Unable to access "default" App object fatal:_NhlCreate:Unable to access "default" App object fatal:NhlDraw: Invalid plot ID: 0 fatal:Unable to update Workstation with PID#0 fatal:Unable to clear Workstation with PID#0 fatal:Unable to Destroy (Bad PID#0) fatal:Unable to Destroy (Bad PID#-4)Omitting
external nhlfcoordarraysrclasswill produce:
fatal:nhlfcreate:Invalid Class Function fatal:Unable to access plot with pid:-4 warning:Unable to add DataItem "(null)" to DataList "xyCoordData" fatal:CompileDataList:DataList has no valid membersYou will get a plot with a grid and no data.
The NCAR Graphics consulting staff is available via e-mail at graphuse@ncar.ucar.edu. Installation consulting is available at ncargfx@ncar.ucar.edu. The comment form is available for submittal from any page of the documentation. Just click on the Feedback icon in the control panel and go from there.
NG4.1 Home, Index, Examples, Glossary, Feedback, UG Contents, UG WhereAmI?