[fdo-users] .net and fdo

Jackie C. Ng jumpinjackie at gmail.com
Tue Dec 2 17:22:35 EST 2008


Hi Matteo,

You need to use a subversion client to download the code. (eg.
http://tortoisesvn.tigris.org)

- Jackie


Matteo-20 wrote:
> 
> 
> Hi Robert,
>   I have try fdotoolbox. It's a very good tool but i don't understand how
> to
> download the code.
> Thanks for the example code.
> 
> 
> 
> Robert Fortin wrote:
>> 
>> Hi Matteo!
>> 
>> I think the FDO tool box would enable you to copy shp to sdf . See
>> http://fdotoolbox.googlecode.com/  There is also .NET code there to look
>> into.
>> 
>> But in order to give you a very brief introduction to get going with .NET
>> FDO...
>> 
>> 
>> -          In order to start you would generally reference OSGeo.Fdo.dll
>> and OSGeo.Fdo.Common.dll (and then add as you need other ones)
>> 
>> -          You can get the list of available provider from
>> OSGeo.FDO.ClientServices.FeatureAccessManager.GetProviderRegistry()
>> 
>> -          You will need to get the connection manager from
>> 
>> OSGeo.FDO.IconnectionManager
>> mConnMgr=OSGeo.FDO.ClientServices.FeatureAccessManager.GetConnectionManager();
>> 
>> 
>> -          Once you know the provider you want to create a connection
>> for,
>> you call CreateConnection on the ConnectionManager for the specific
>> provider named.
>> 
>> OSGeo.FDO.Connections.Iconnection mProvConn =
>> mConnMgr.CreateConnection("OSGeo.SDF.3.3");
>> 
>> 
>> -          From the connection, you can get the connection Info object
>> which has the list of connection parameters. This varies depending on the
>> provider.
>> 
>> OSGeo.FDO.Connections.IConnectionInfo connInfo =
>> mProvConn.ConnectionInfo;
>> OSGeo.FDO.Connections.IConnectionPropertyDictionary connPropDict =
>> connInfo.ConnectionProperties;
>> connPropDict.SetProperty("File", "myfile");
>> 
>> 
>> -          Once you are done setting the connection parameters, open the
>> connection
>> 
>> mProvConn.Open();
>> 
>> 
>> -          From that point on, you can create commands to described the
>> schema
>> 
>> OSGeo.FDO.Commands.Schema.IDescribeSchema schemaCmd
>> mProvConn.CreateCommand(OSGeo.FDO.Commands.CommandType.CommandType_DescribeSchema);
>> OSGeo.FDO.Schema.FeatureSchemaCollection schemaCol = schemaCmd.Execute();
>> 
>> 
>> o   Or select/update/delete the data or to retrieve the schema.
>> 
>>       OSGeo.FDO.Commands.Feature.ISelect selCmd =
>> (OSGeo.FDO.Commands.Feature.ISelect)(OSGeo.FDO.Commands.Feature.ISelectAggregates)mProvConn.CreateCommand(OSGeo.FDO.Commands.CommandType.CommandType_Select);
>>       selCmd.SetFeatureClassName("myclass");
>>       OSGeo.FDO.Commands.Feature.IReader myReader = selCmd.Execute();
>>       while (myReader.ReadNext())
>>       {
>>          string aStr = myReader.GetString("some_property");
>>       }
>> 
>> Hope this can get you started.
>> 
>> Robert
>> 
>> From: fdo-users-bounces at lists.osgeo.org
>> [mailto:fdo-users-bounces at lists.osgeo.org] On Behalf Of Matteo
>> Sent: Tuesday, December 02, 2008 1:17 PM
>> To: fdo-users at lists.osgeo.org
>> Subject: [fdo-users] .net and fdo
>> 
>> Hi all, I would to create an application (vb.net or c#) that convert shp
>> file to sdf 3. I'm new in fdo tecnology and I don't know the basic step
>> for develep with FDO. For example: 1) How dll i must be reference in my
>> .net project? 2) What is the connection string to connect to a shp file?
>> I
>> don't find some examples Regards Matteo
>> ________________________________
>> View this message in context: .net and
>> fdo<http://n2.nabble.com/.net-and-fdo-tp1605124p1605124.html>
>> Sent from the FDO Users mailing list
>> archive<http://n2.nabble.com/FDO-Users-f737950.html> at Nabble.com.
>> 
>> _______________________________________________
>> fdo-users mailing list
>> fdo-users at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/fdo-users
>> 
>> 
> 
> -- 
> View this message in context:
> http://n2.nabble.com/.net-and-fdo-tp1605124p1605707.html
> Sent from the FDO Users mailing list archive at Nabble.com.
> 
> _______________________________________________
> fdo-users mailing list
> fdo-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/fdo-users
> 
> 


-----
http://themapguyde.blogspot.com

http://www.linkedin.com/in/jackieng
-- 
View this message in context: http://www.nabble.com/.net-and-fdo-tp20797931p20802361.html
Sent from the FDO Users mailing list archive at Nabble.com.



More information about the fdo-users mailing list