POST
|
Hi, We're building a plug-in data source. The data is typical WGS1984 lat/lng data. In the plugin data source, we're creating the spatial reference with code similar to the following: var spatialReferenceFact = new SpatialReferenceEnvironmentClass(); shapeField.SpatialReference_2 = spatialReferenceFact.CreateGeographicCoordinateSystem(6326); Problem is, when I try to drop the plug-in data source on a map, I get the following error: Error opening feature class. The specified WKID (factory code) or WKT (definition string) is not a Projected Coordinate System. I'm curious why it's wanting a projected coordinate system. According to the docs, I should be able to use a Geographic Coordinate System with a plug-in data source. Any suggestions?
... View more
10-12-2012
12:01 PM
|
0
|
2
|
1378
|
POST
|
Thanks Kevin! Your suggestion worked. It actually prompted me when publishing that it was copying the scripts folder and did move it and update the original script correctly. One other thing I found, in my original script, I had a few imports to modules from the 3rd party site-package I mentioned. Those modules weren't used in the script, they just hadn't been removed from the import. When I take out the 3rd party imports and publish, then ADSSurface.py is copied to the server. When I add back the 3rd party imports and publish, ADSSurface.py is NOT copied. In either case, if I follow your suggestion using sys.path.append, then ADSSurface.py is copied over and everything works.
... View more
09-21-2012
09:25 AM
|
0
|
0
|
323
|
POST
|
Thanks for the quick response Kevin. That article is very helpful. However, it doesn't seem to be working as it's described. The script I'm trying to publish looks like this: import arcpy
from ADSSurface import ADSSurface
fieldId = arcpy.GetParameterAsText(0)
year = arcpy.GetParameter(1)
surface = ADSSurface(fieldId, year)
raster = surface.getRaster()
arcpy.SetParameter(2, raster) ADSSurface.py is in the same folder as this script (GetSurface.py) and it contains all of our custom logic. After I publish and look in the server directories, the published script (GetSurface.py) is identical to the original script and when I run on server, I get an error something like "ADSSurface not found." There is no sign of ADSSurface.py embedded or standalone on the server. Is there something that controls whether the published script embeds its dependencies or not? Anything that could prevent the embed from happening? ADSSurface uses a 3rd party site-package that is installed on the server. Would that cause ArcGIS to not embed dependencies?
... View more
09-21-2012
08:21 AM
|
0
|
0
|
323
|
POST
|
I have a custom script tool (python) that uses some classes defined in separate .py files. When I publish the tool to ArcGIS server only the script is deployed, but its dependencies are left behind. Is there any way to package python dependencies with a tool so they are deployed with the tool? I'm using version 10.1.
... View more
09-21-2012
06:00 AM
|
0
|
5
|
1051
|
POST
|
I'm getting the same error on my feature service - attempting to add a feature. I'm not attempting to do anything with attachments, but getting the error that "Table attachments not supported." I'm also on a SDE 9.3.1 database. Is SDE 10 required to use the feature services?
... View more
12-16-2011
09:34 AM
|
0
|
0
|
455
|
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:24 AM
|