Generating for Java Web HTML and get errors: image file not found in Gen
search cancel

Generating for Java Web HTML and get errors: image file not found in Gen


Article ID: 269075


Updated On:


Gen Gen - Host Encyclopedia Gen - Run Time Distributed Gen - Workstation Toolset


Attempted to generate a Client Procedure in the Toolset that were GUI 'C' clients, but now are Java Web clients.   

Get several of the following errors for different images: 

"Image file not found C:\........\<image_name>.jpg



Release : 8.6


For GUI applications, the accepted bitmap format as documented are: .PPM, .BMP, .ICO or .DIB and for GUI these bitmaps are placed in the /bitmap directory within the local model. 

To reference these bitmaps targeting html (JVM/Java), users need to create a '.jpg' version of the same bitmaps and place them within the local models '/html/images' directory, along with keeping the .bmp version within the '/bitmap' directory.  This will allow the generation process to find the bitmaps, complete the generation process and display them properly at runtime of the application.

Additional information regarding the image not found error and bitmaps when going from GUI to Web:

1.  In testing of bitmap images referenced in web, by default the image file names need to be all lowercase in order to display correctly on the deployed web pages.  There may be steps that can be taken to change this by adjusting the naming within the generated .html before the assembly process, if needed.    

2.  There are differences for bitmaps regarding multi-state images between GUI and Web.   In GUI applications, when they contain multi-state images, all images (ex. enabled, disabled, pushed, focused) can be in one bitmap.  But when switching to a Web Generation application, users will need to have separate image files for each image state that is to be used and the file name(s) will need to have the image state in the name (ex. closetb_pushed.jpg, closetb_focused.jpg).
Here is a link to this topic within our Gen 8.6 Technical Documentation (see the 'Change Multi-State Images Dynamically' section at the bottom of this web page):