[fdo-users] New FDO Provider and using it in Map 3D

Greg Boone greg.boone at autodesk.com
Tue Sep 11 18:52:02 EDT 2007

Thanks Robert! This will help the community at large.


-----Original Message-----
From: fdo-users-bounces at lists.osgeo.org
[mailto:fdo-users-bounces at lists.osgeo.org] On Behalf Of Robert Fortin
Sent: Tuesday, September 11, 2007 5:51 PM
To: FDO Users Mail List
Subject: RE: [fdo-users] New FDO Provider and using it in Map 3D

Hi Piet!

You could have expected the Map FDO Data Connect Dialog to look for the
properties IsPropertyFileName or IsPropertyFilePath from the
IPropertyDictionary interface to figure out if a connection property is
a file or a path and, base on that, show proper control to select either
a file or a path.  But it is not the case!  The default dialog that you
see doesn't make use of those properties.  

BUT There is a solution to your problem: define a custom connection
control specific to your provider that would show into the Data connect
dialog.  It is documented in the document help/sdk.dev.net.gis.chm under
Map install path.  Look for Data Connect and follow the instructions.

To help you get started, I have attached a sample that work with the SDF
provider renamed to OSGeo.MYSDF.3.2.  Just update the reference to the
FDO, Autodesk and Map dlls and build it.  Then put the dll under
<Map>/Plugins/DataConnect. Edit the providers.xml file and change or
create a copy of the SDF info and change the name to

After that, when you start Map, a special UI will let you pick the name
of an SDF file by selecting the MYSDF provider. 

Hope it helps.


-----Original Message-----
From: fdo-users-bounces at lists.osgeo.org
[mailto:fdo-users-bounces at lists.osgeo.org] On Behalf Of Piet Bibber
Sent: Tuesday, September 11, 2007 5:20 AM
To: fdo-users at lists.osgeo.org
Subject: [fdo-users] New FDO Provider and using it in Map 3D

I have just created a new FDO Provider (supporting Nen1878) and
struggling with 2 items:

1) the icon in the 'data connect'-dialog indicates a database, yet the
GetProviderDatastoreType returns FdoProviderDatastoreType_File
1a) what do I need to implement to get the browse for file and browse
for directory buttons?

2) The Geometry column shows a 0 (zero) for Geometric Types, albeit I
return a 'FdoGeometryType_Point' primitive in CreateCachedGeometry
(called by 'virtual FdoByteArray* GetGeometry (FdoString* identifier)')

FdoGeometryType fdoGeomType  = FdoGeometryType_Point;
FdoInt32        dimensionality = FdoDimensionality_XY;
FdoInt32        numPointOrds = 2; // Always 2. (No Z or M)
FdoInt32        numPositions = 1;


fgfByteArray = FdoByteArray::Append(fgfByteArray, sizeof(fdoGeomType),
(FdoByte *) &fdoGeomType);

DoublePoint dp(0.,0.);

numBytesForOrdinates = numPointOrds * sizeof(double) * 1; fgfByteArray =
(FdoByte *) &dimensionality );
fgfByteArray = FdoByteArray::Append(fgfByteArray, numBytesForOrdinates,

(FdoByte *)&dp );

Q1: When is the Geometric Type set? During schema creation or when
passing the geometry (I think the latter)

Thanks up front
// Piet
View this message in context:
Sent from the fdo-users mailing list archive at Nabble.com.

fdo-users mailing list
fdo-users at lists.osgeo.org

More information about the fdo-users mailing list