GoldMine Application Programming Interface Specification and Reference



Download 465.93 Kb.
Page3/4
Date31.01.2017
Size465.93 Kb.
#14243
1   2   3   4

Properties

SystemFolder


This is a string property that contains the location of the LICENSE.DBF file. This property maps to the Goldmine API szSysDir parameter in the call to GMW_LoadBDE.

GoldmineFolder


This is a string property that contains the location of the CAL.DBF file This property maps to the Goldmine API szGoldDir parameter in the call to GMW_LoadBDE.

CommonFolder


This is a string property that contains either the location of CONTACT1.DBF, or the BDE alias used to access the database. For example, to access SQL Server, an alias of MSSQL_Goldmine might be configured. The string to access this would be “MSSQL: MSSQL_GoldMine: dbo:”.

GMUserName


This is a string property that contains the user name to be used to login to GoldMine. All GoldMine user ids are all upper case, so the GMApplication object will convert this property to uppercase when a login occurs.

GMPassword


This is a string property that contains the password used to login to GoldMine. This is a write only property.

SQLUserName


This is a string property that contains the SQL Server user id if the underlying database is SQL server.

SQLPassword


This is a string property that contains the password for the SQL server account used if the database is SQL server. This is a write only property.

LicenseInfo


This is an object containing all the license information for the current installation.

Methods

Login


This method Loads the BDE (if it has not already been loaded), and logs the user in using the properties as they have been set.

Logout


This method logs out the logged in user.

NewContainer


This method creates a new blank Name/Value pair container object, and returns it.

Execute


This method takes as parameters a Business Logic Function name (eg “WriteContact”) and a Container object containing the Name/Value pairs for the transaction. It then executes the transaction, and updates the pairs in the container with the results.

NewWorkArea


Creates a new work area on the specified table.
The Container class.

This class cannot be created directly, but should always be created using the NewContainer method on the GMApplication class. This class supports collection semantics to enable the client access to the Name/Value pairs stored internally. By behaving like a collection, the Container is simple to use for developers used to the Collection paradigm so prevalent in the VBA/VB/VBS world.


The general scenario for use of a Container would be to Create the container, Add a number of Name/Value pairs, Execute a transaction, Read the results out of the Container.

Properties

Count


This returns the number of Name/Value pairs in the container.

_NewEnum


This property is hidden from VB clients. It returns an enumerator into the collection. This can be used from VB using the For Each object in Collection syntax. C++ clients will use this interface as an IEnumVARIANT* to do the enumeration.

Add


Adds a new entry to the collection. The Add method takes a Name and a Value as parameters, and creates a new NVPair, which it returns. The Value is an optional parameter which defaults to an empty string. If an empty string is passed for the value (or if the optional parameter is left out), the pair is created with no value. This is useful for creating multi value pairs.

Remove


Removes the pair specified by the name.

Methods

Item


This method is the default method for the class. It takes a name as a parameter, and returns the name value pair that corresponds to that name.

CopyFrom


Converts this container into a copy of the container passed in.

Copy


Makes a copy of this container and returns it.

The Name/Value Pair Class

This class encapsulates a single name/value pair. Because a Name/Value pair could have multiple values, this class is modeled as a collection of strings, where each string represents a single value. Because the Item method is the default method, and the default parameter is 1, VB clients will see the first entry in the collection as the Value of the object. When a GMNVPair object is created using the Add method on the container the pair has a single value. If the client wishes this to be a multivalue pair, then Successive calls to Add on the GMNVPair class will append values. These values can be enumerated using the standard collection semantics.

Properties

Count


Returns the number of values in this N/V Pair.

Name


The Name of the N/V Pair

_NewEnum


An enumerator to enumerate the Values. Invisible to VB clients.

Methods

Add


Appends a value to the end.

Item


Returns the specified value. This takes a long as the index parameter. The index is 1 based. This is the default Method, and the default parameter is 1.
The WorkArea Class

This class encapsulates the Work Area functions in the Low Level API. Each method corresponds to an underlying function, and is simply a thin wrapper around the function.


Methods

Append


Adds a new record, and returns the new record ID

Replace


Replaces a specific field at the current position

Delete


Deletes the current record

Unlock


Unlocks after an update or an append has locked the work area

Read


Reads the contents of the specified field at the current position

Top


Sets the current position to the top of the work area

Bottom


Sets the current position to the bottom of the work area

SetOrder


Sets the current index tag on the table

Seek


Positions to the first record matching the seek value

Skip


Skips the specified number of records

Goto


Moves to the specified record

Move


Positions the record pointer to a particular record in a data file

Search


Performs a sequential search on a file

Filter


Limits access to data in a GoldMine database by creating a subset of records based on expression criteria.

Range


Activates the index in a table, and set a range of values to limit the scope of data that GoldMine will search

RecNo


Used to determine either current record number position (dBASE), or the record ID (SQL)

IsSQL


Used to determine if the table is SQL (1) or dBASE (0).

The LicenseInfo Class

This class encapsulates the License Information of the current server. It is accessed from the Application object as a property.



Download 465.93 Kb.

Share with your friends:
1   2   3   4




The database is protected by copyright ©ininet.org 2024
send message

    Main page