MapWinGIS:Image Open

This is a back-up of the WIKI.
Not all links might work
We're working on a new wiki.

Main Page | Recent changes | View source | Page history | Log in / create account |

Printable version | Disclaimers | Privacy policy

Open

Opens an image from file.


VB.NET Usage

Function Open(ImageFileName As String, Optional FileType As MapWinGIS.ImageType, Optional InRam As Boolean, Optional cBack As MapWinGIS.ICallback) As Boolean

            Parameters

ImageFileName

The filename of the image to be opened.
FileType Optional. The type of image being opened. The default is "USE_FILE_EXTENSION".
InRam Optional. A boolean value representing whether the image is stored in RAM memory while open. The default is True. However, for bitmap images there is a considerable perfomance improvement if you set this to False.
cBack Optional. The ICallback object which will receive progress and error events while the image is being opened.
ReturnValue A boolean value representing the success or failure of opening the image.

Sample Code

    Private Sub OpenImage()
        Dim image As New MapWinGIS.Image()
        Dim success As Boolean
        'Open image from file
        success = image.Open("C:\test.bmp")
        'If the image wasn't opened successfully, display an error message
        If Not success Then
            MsgBox("There was an error opening the image.")
        End If
    End Sub
  

VB 6 Usage
Function Open(ImageFileName As String, Optional FileType As ImageType, Optional InRam As Boolean, Optional cBack As ICallback) As Boolean
            Parameters

ImageFileName

The filename of the image to be opened.
FileType Optional. The type of image being opened. The default is "USE_FILE_EXTENSION".
InRam Optional. A boolean value representing whether the image is stored in RAM memory while open. The default is True.
cBack Optional. The ICallback object which will receive progress and error events while the image is being opened.
ReturnValue A boolean value representing the success or failure of opening the image.

Sample Code

    Private Sub OpenImage()
        Dim image As New MapWinGIS.image
        Dim success As Boolean
        'Open image from file
        success = image.Open("C:\test.bmp")
        'If the image wasn't opened successfully, display an error message
        If Not success Then
            MsgBox ("There was an error opening the image.")
        End If
    End Sub

Retrieved from "http://mapwindow.org/wiki/index.php/MapWinGIS:Image_Open"

This page has been accessed 3,725 times. This page was last modified on 24 November 2009, at 07:56.