MapWinGIS:Utils GridToGrid

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

GridToGrid

Creates a new grid of the same size as the original grid, converting the values of the original grid into a different data type in the new grid.
See also Grid and GridDataType


VB.NET Usage

Function GridToGrid(Grid As MapWinGIS.Grid, OutDataType As MapWinGIS.GridDataType, Optional cBack As MapWinGIS.ICallback) MapWinGIS.Grid

            Parameters

Grid

The original grid.
OutDataType The data type to convert the original grid values to for the new grid values.
cBack Optional. The ICallback object which will receive progress and error messages while the original grid values are converted and copied into the new grid.
ReturnValue The new grid filled with the converted values of the original grid.

Sample Code

    Private Sub GridToGrid()
        Dim originalgrid As New MapWinGIS.Grid(), newgrid As New MapWinGIS.Grid()
        Dim utils As New MapWinGIS.Utils()
        'Create the new grid using the values of the originalgrid by converting them to Double
        newgrid = utils.GridToGrid(originalgrid, MapWinGIS.GridDataType.DoubleDataType, Me)
    End Sub
  

VB 6 Usage
Function GridToGrid(Grid As Grid, OutDataType As GridDataType, Optional cBack As MapWinGIS.ICallback) MapWinGIS.Grid
            Parameters

Grid

The original grid.
OutDataType The data type to convert the original grid values to for the new grid values.
cBack Optional. The ICallback object which will receive progress and error messages while the original grid values are converted and copied into the new grid.
ReturnValue The new grid filled with the converted values of the original grid.

Sample Code

    Private Sub GridToGrid()
        Dim originalgrid As New MapWinGIS.grid, newgrid As New MapWinGIS.grid
        Dim utils As New MapWinGIS.utils
        'Create the new grid using the values of the originalgrid by converting them to Double
        Set newgrid = utils.GridToGrid(originalgrid, MapWinGIS.GridDataType.DoubleDataType, Me)
    End Sub

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

This page has been accessed 1,277 times. This page was last modified on 9 November 2005, at 17:36.