GridConvert
The GridConvert method is superseded by GridConvert2. Please consider using the more recent version. GridConvert has been retained for backward compatibility only.
GridConvert converts between various grid formats. Returns a Boolean. Returns 'True', if the conversion operation is successful, otherwise, it returns 'False'.
Syntax
object.GridConvert( InGrid, OutGrid, OutFmt )
Parameter |
Type |
Required/ Optional |
Default |
Description |
InGrid |
String |
Required |
|
This provides the path and file name of the input grid file. |
OutGrid |
String |
Optional |
"" |
This provides the path and file name of the output grid file name. |
OutFmt |
Optional |
srfGridFmtS7 |
This provides the output grid file format. |
Remarks
GridConvert converts any supported grid file format to any other supported grid file format or an ASCII XYZ .DAT data file.
Example 1
This example demonstrates how to convert demogrid.grd into an ASCII data file called dgrid1.dat that stores the X, Y, and Z coordinates of each grid node on a separate line.
SurferApp.GridConvert(InGrid:=SurferApp.Path+"\Samples\demogrid.grd", _
OutGrid:=SurferApp.Path+"\Samples\dgrid1", OutFmt:=srfGridFmtXYZ)
Example 2
This script displays all the methods in the Application object.
Used by: Application object