This documentation is archived and is not being maintained.
Imagelist.add Method [AX 2012]
Adds a new image to the image list.
public int add(Image image)
Run On
Client
Parameters
-
image
- Type: Image Class
The new image to add to the list.
Return Value
Type:
int
0 indicates success; otherwise, failure.
You can use the autoResize method to automatically resize images when you add them to the list.
The following example creates a new image list and adds 3 images to the list.
ImageList list = new Imagelist(
Imagelist::smallIconWidth(),
Imagelist::smallIconHeight());
list.add(new Image(3104));
list.add(new Image(1097));
list.add(new Image(1200));
// Prints 3
print list.count();
pause;