' Create the geoprocessor. Dim gp As IGeoProcessor2 = New GeoProcessor() Dim pGPResult As IGeoProcessorResult = New GeoProcessorResult() gp.OverwriteOutput = True ' Create a variant array to hold the parameter values. Dim parameters As IVariantArray = New VarArray() Dim sev As Object = Nothing Try ' Populate the variant array with parameter values. With parameters .Add(sGPXFullName) .Add(sFDatasetPath & sTempFCName) End With ' Execute the tool. pGPResult = gp.Execute("GPXToFeatures_conversion", parameters, Nothing) ' Wait until the execution completes. While (pGPResult.Status = esriJobStatus.esriJobExecuting) Thread.Sleep(1000) End While ' Print geoprocessing messages. Console.WriteLine(gp.GetMessages(sev)) Catch ex As Exception ' Print generic exception messages. Console.WriteLine(ex.Message) ' Print geoprocessing execution error messages. Console.WriteLine(gp.GetMessages(sev)) End Try
Přihlášení členové mohou přispívat, sledovat aktualizace a další. Jste tu noví? Zaregistrujte si bezplatný účet.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.