Re: Newbie
- From: Barry <Barry@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Fri, 1 Feb 2008 10:20:00 -0800
Got it, with much help from Bob Barrows.
Thanks to you all for your help!
Script follows:
Attribute VB_Name = "TabletoFeatureClass"
' ---------------------------------------------------------------------------
' TabletoFeatureClass.vbs
' Created on: Tue Jan 29 2008 10:53:52 AM
' (generated by ArcGIS/ModelBuilder)
' ---------------------------------------------------------------------------
Sub TabletoFeatureClass()
' Create the Geoprocessor object
Set gp = CreateObject("esriGeoprocessing.GPDispatch.1")
' Load required toolboxes...
gp.AddToolbox "D:/Program Files/ArcGIS/ArcToolbox/Toolboxes/Data Management
Tools.tbx"
' Local variables...
SDE_XYWells_end = "Database
Connections\apps1.sde\SDE.test_data\SDE.XYWells_end"
Well_test = "D:\test\Well_Annotation.mdb\Well_test"
XYWells_Layer = "Well_test_Layer"
Spatial_Grid_Index = "5471.67632751153"
Spatial_Grid_Index2 = "0"
Spatial_Grid_Index3 = "0"
' Process: Make XY Event Layer...
gp.MakeXYEventLayer_management Well_test, "EASTING", "NORTHING",
XYWells_Layer,
"PROJCS['NAD_1983_StatePlane_Texas_North_FIPS_4201_Feet',GEOGCS['GCS_North_American_1983',DATUM['D_North_American_1983',SPHEROID['GRS_1980',6378137.0,298.257222101]],PRIMEM['Greenwich',0.0],UNIT['Degree',0.0174532925199433]],PROJECTION['Lambert_Conformal_Conic'],PARAMETER['False_Easting',656166.6666666665],PARAMETER['False_Northing',3280833.333333333],PARAMETER['Central_Meridian',-101.5],PARAMETER['Standard_Parallel_1',34.65],PARAMETER['Standard_Parallel_2',36.18333333333333],PARAMETER['Latitude_Of_Origin',34.0],UNIT['Foot_US',0.3048006096012192]];IsHighPrecision"
' Process: Copy Features...
gp.OverwriteOutput = 1
gp.CopyFeatures_management XYWells_Layer, SDE_XYWells_end, "", "0", "0", "0"
' Process: Calculate Default Spatial Grid Index...
gp.CalculateDefaultGridIndex_management SDE_XYWells_end
End Sub
--
Barry Guidry
"Bob Barrows [MVP]" wrote:
Barry wrote:.
It is working as scripted below, thanks very much to Mr. Barrows for
his assistance. However, once the feature class is created, the
script will not update it as written. The error occurs at line:
gp.CopyFeatures_management XYWells_Layer, XYWells_end, "", "0", "0",
"0"
Any idea if I can add something to either update it if it exists, or
delete it first?
Nope. I have no clue what this object is doing. You need to contact the
person who created that class library.
--
Microsoft MVP -- ASP/ASP.NET
Please reply to the newsgroup. The email account listed in my From
header is my spam trap, so I don't check it very often. You will get a
quicker response by posting to the newsgroup.
- Prev by Date: Re: 32-bit Application using ADO under 64-bit OS (Windows Server 2003)
- Next by Date: Re: 32-bit Application using ADO under 64-bit OS (Windows Server 2003)
- Previous by thread: Re: 32-bit Application using ADO under 64-bit OS (Windows Server 2003)
- Next by thread: Re: slow insert a lot of row from table adapter to sql table, improve?
- Index(es):
Relevant Pages
|
Loading