Hello everyone,
I am using an updated MS Access database which has an historical legacy for data input in an organisation (there is still historical information to input) I am working for. the database calls a conversion tool from the ArcGIS Toolbox for Geoprocessing. However, this code does not appear to be working. Have seen the following article, although no solution here (see additional PDF attached is there a solution here?):
https://gis.stackexchange.com/questions/10801/call-tools-from-arctoolbox-in-vba-form
Below is the VB code (see attached document as well):
Private Sub Label38_Click()
' ---------------------------------------------------------------------------
' OGW All Projects export
' ---------------------------------------------------------------------------
' Create the Geoprocessor object
Set gp = CreateObject("esriGeoprocessing.GPDispatch.1")
' Load required toolboxes...
gp.AddToolbox "C:\Program Files\ArcGIS\Pro\Resources\ArcToolBox\toolboxes\Conversion Tools.tbx"
' Script arguments...
'OGWReporting_mdb = Arguments.Item(0)
'if OGWReporting_mdb = "#" Then
OGWReporting_mdb = "I:\Database\OGW_Database\OGW_Reporting\AllOGWReporting.accdb" ' provide a default value if unspecified
'End If
' Local variables...
GWLAP_Funded_Works_lyr = "I:\Database\OGW_Database\OGW_Layers\Archives\All Works.lyr"
GWLAP_Funded_Fence_Lines_lyr__2_ = "I:\Database\OGW_Database\OGW_Layers\Archives\All Fence Lines.lyr"
Derived_Geodatabase = "I:\Database\OGW_Database\OGW_Reporting\AllOGWReporting.accdb"
' Process: Feature Class to Geodatabase (multiple)...
gp.FeatureClassToGeodatabase.tool "'I:\Database\OGW_Database\OGW_Layers\Archives\All Works.lyr';'I:\Database\OGW_Database\OGW_Layers\Archives\All Fence Lines.lyr'", OGWReporting.accdb
'MsgBox "Complete"
'End ESRI Model
Have updated the code to reflect the most recent versions of MS Access and ArcGIS any assistance would be much appreciated.
Many thanks, Davina