User Tools

Site Tools


k23:k23.4:k23.4.2:k23.4.2.4:start

23.4.2.4 Class ImageStat (gb.image)

This class enables the return of selected information about a specific image. The class cannot be generated and can be used as a static function.

The static function:

Static Function ImageStat ( ImagePath As String ) As ImageStat

returns information about the image specified in the “ImagePath” argument.

23.4.2.4.1 Example:

Public Sub Form_Open()
 
  Dim statImage As ImageStat
 
  statImage = ImageStat(User.Home &/ "Pictures/example.jpg")
 
  Print "Image Depth = " & statImage.Depth
  Print "Image Height = " & statImage.Height
  Print "Image Width = " & statImage.Width
  Print "Image Path = " & statImage.Path
  Print "Image Type = " & statImage.Type
 
End

23.4.2.4.2 Properties

The following table describes the properties of the class:

PropertyTypeDescription
DepthIntegerReturns the colour depth of the image in bits.
HeightIntegerReturns the height of the image in pixels.
WidthIntegerReturns the image width in pixels.
PathStringReturns the path of the image.
TypeStringReturns the mimetype of the image as a string. The string can be “image/jpeg”, “image/gif”, “image/png”, “image/bmp” or “image/tiff”.

Table 23.4.2.4.1 : Properties class ImageStat (gb.image)

This website uses cookies. By using the website, you agree with storing cookies on your computer. Also you acknowledge that you have read and understand our Privacy Policy. If you do not agree leave the website.
k23/k23.4/k23.4.2/k23.4.2.4/start.txt · Last modified: by 127.0.0.1