Maptitude GISDK Help

CreateDataCursor()

Summary

Creates a Data Cursor, a GISDK object that can be used to navigate and read tabular data.

 

Changes

Added to Version 2013.

 

Syntax

cursor = CreateDataCursor(string view_set[, array options])

 

Argument

Contents

view_set

The view, and optionally set, of target records

 

Option

Type

Contents

Order

Array

An array of 2-element arrays specifying the sort order for navigating the records; in each pair the first element is the field name and the second elements is either of the strings "Ascending" or "Descending".

Fields

Array

An array of field names specifying the fields whose values should be pre-fetched when navigating the cursor. This can improve reading performance for certain data sources such as ODBC, Oracle, SQL Server, etc.

Query Field

String

A field to use for matching against the value specified by the Query Value option. Only records matching this value will be included in the cursor. If you use this option, you must have a Query Value option.

Query Value

Any

The value to be matched against the Query Field. If you use the Query Field option, you must use this option.

 

Returns

A Data Cursor GISDK object.

 

Notes

Example

// First, create the view

view = OpenTable("State Data", "DBASE", {"c:\\dbf\\states.dbf",} )

// Create a data cursor for navigation

cursor = CreateDataCursor(view)

while cursor.Fetch() != null do

// read the state name and population

name = cursor.GetValue("Name")

pop = cursor.GetValue("Population")

// Display the information

str = "The population of " + name + " is " + String(pop)

ShowMessage(str)

end

 

 

©2025 Caliper Corporation www.caliper.com