Working with Images that Contain Multiple Sub-Images

Description

An image can contain multiple sub-images. For example, the Alpha Anywhere system image called 'filebox' contains sub-images. The following script displays a dialog showing the 'filebox' image:

ui_dlg_box("Filebox",<<%dlg%
{image=filebox}
%dlg%)

This script produces the following dialog:

 Lesson 13: Image with multiple sub-images

The filebox image contains 8 sub-images. You can select a sub-image from an image using the syntax:

%I=imagename:image_number:image_count%

For example, to select the 2 nd image from the filebox, (which has 8 sub-images in total), you would use the following syntax:

%I=filebox:2:8%

The following dialog uses the 2 nd (of 8) and 7 th (of 8) sub-image on buttons.

result = ui_dlg_box("Bitmap Buttons",<<%dlg%
Expression:[.64expression];
<%I=filebox:2:8%open> <%I=filebox:7:8%new> <*OK> 
%dlg%)

This script produces the following dialog:

Limitations

Desktop applications only

See Also