Image.new Method

Initializes a new instance of the BinData class.

Syntax

public void new(
   [anytype image, 
    int width, 
    int height])

Run On

Client

Parameters

  • image
    Type: anytype
    An existing image; optional.
  • width
    Type: int
    The width of the image in pixels; optional.
  • height
    Type: int
    The height of the image in pixels; optional.

Remarks

You do not need to specify any parameters, but it is possible to specify the image contents and size. For the image parameter, you can specify a file name and location, a resource, a particular image in an array, or another Image object.

Examples

The following examples illustrate how you can optionally specify the existing content for the new image object.

Image img1 = new Image(@"C:\MyPicture.jpg", 100, 100); 
Image img2 = new Image(121,100, 100); // Uses resource 121 in Ax32.exe 
Image img4 = new Image(img1, 200, 200);

See Also

Reference

Image Class