SetDSInstancePtr Method

[VB]

Public Sub SetDSInstancePtr(ByRef value As System.IntPtr)

[C#]

public void SetDSInstancePtr(System::IntPtr value);

 

Description

This function is used for cross Library development. It takes a pointer to an already created Datasource object.  If you are using the GeoTransform raster image library, or the GeoTranslate vector processing library, it is possible to share the same GeoCalc datasource.  This allows you to manage and maintain coordinate systems from multiple application in one central repository.
 

Example

[VB]

Private Sub GeoCalcNET_DataSourceComponent()

Dim data1 As New GeoCalcNET.DataSourceComponent
Dim data2 As New GeoCalcNET.DataSourceComponent

data1.LoadFile("C:\bmg\GeoCalcNET\data\GeoData.xml")
data2.SetDSInstancePtr(data1.GetDSInstancePtr)

End Sub

[C#]

private void GeoCalcNET_DataSourceComponent()

{

GeoCalcNET.DataSourceComponent data1 = new GeoCalcNET.DataSourceComponent();
GeoCalcNET.DataSourceComponent data2 = new GeoCalcNET.DataSourceComponent();

data1.LoadFile("C:\bmg\GeoCalcNET\data\GeoData.xml");
data2.SetDSInstancePtr(data1.GetDSInstancePtr);

}