I have a SDF file and I want to add to MAP with MAPCONNECT.
After, I am wanting execute "Add to Map".
I can't find it for 10 days, I could not do
![cengizincebi_0-1718190770981.png cengizincebi_0-1718190770981.png](https://forums.autodesk.com/t5/image/serverpage/image-id/1374881iF1EF457BB9F79725/image-size/medium?v=v2&px=400)
Code is see the SDF file, but can not add to the Data Connect Window (mapconnect) in the code below
Can you help me?
I have next plan connect with .xlsx file :))
Maybe , after that I can add queries and Filters.
-I will definitely add- :))))
CODE:
Private Sub Button8_Click(sender As Object, e As EventArgs) Handles Button8.Click
Dim connectionManager As OSGeo.FDO.IConnectionManager = FeatureAccessManager.GetConnectionManager()
Dim Provider As String = "OSGeo.SDF.4.2"
Dim conn As IConnection = connectionManager.CreateConnection(Provider)
Dim fileName As String = "C:\Temp\Test20.SDF"
conn.ConnectionInfo.ConnectionProperties.SetProperty("ReadOnly", False.ToString())
conn.ConnectionInfo.ConnectionProperties.SetProperty("File", fileName)
conn.ConnectionInfo.ConnectionProperties.SetProperty("MaxCacheSize", False.ToString())
Dim connInfo As IConnectionInfo = conn.ConnectionInfo
Dim properties As IConnectionPropertyDictionary = connInfo.ConnectionProperties
conn.Open()
conn.Close()
End Sub