POST
|
I have similar problem when I tried to migrate my 9.3 C# code to 10.0. I got error message for ISpatialReferenceFactory spatialReferenceFactory2 = new SpatialReferenceEnvironmentClass(); the error message is "Retrieving the COM class factory for component with CLSID {7B5B7020-C4F6-11D1-BC92-0000F875BCCE} failed due to the following error: 80040111." Then I tried to use activator so I revised the code to following: // Set up the SpatialReferenceEnvironment. // SpatialReferenceEnvironment is a singleton object and needs to use the Activator class. Type factoryType = Type.GetTypeFromProgID("esriGeometry.SpatialReferenceEnvironment"); System.Object object1 = Activator.CreateInstance(factoryType); ISpatialReferenceFactory2 spatialReferenceFactory2 = object1 as ISpatialReferenceFactory2; However, I still got the same error message. Can anyone help on this one? Thanks a lot. Wei Hi Wei, Another post with a similar issue said that he needed to add this: ESRI.ArcGIS.RuntimeManager.Bind(ESRI.ArcGIS.ProductCode.Engine); (or other licensing information). Melita
... View more
10-19-2010
11:41 AM
|
0
|
0
|
981
|
POST
|
Hi Melita, Your understanding of the problem sounds correct but I may not be attempting to solve it properly. If you have any samples source code that I can look at, I would appreciate it. Just to clarify what i m attempting: I am reading data from our DB, creating features in several feature classes that exist in in-memory-workspaces, After building all of the feature classes, I want to center the map on the visible features. The original data is stored in decimal degrees but the map is displayed using Mercator projection with meter units. I am able to project the original data to mercator without any issue. After all the data has been processed, I want to cener the map on the visible data. I am attempting to do this by changing the central meridian from 0, to an appropriate value. This seems to be where my problem is. I am calculating the visible data by examing the extent of certain feature classes of my data. While running the application, I can reload some data and I want to repopulate some (but not all) of the feature classes and re-center on this data. For performance reasons, I am attempting to leave some of the feature classes alone and not re-load / re-process this data. On the map, I am displaying the sample world shape file that came with the sample application data. When I recenter the map, the shape file displays correctly, with the new central meridian. My feature class data does not appear correct. For example, if I change the central meridian to 180 degrees, the IDL of the shape file is displayed on the center of my map. The coordinates that I display tracking the mouse movement are correct as well. It is just the features related to the feature classes I created, that do not display correctly. Any ideas on what I am doing wrong? Thanks, Gary Hi Gary, The only thing I can think of is that the new feature layers don't have any coordinate system attached to them. If you check them in ArcMap, is their coordinate system "Unknown"? Melita
... View more
10-18-2010
04:07 PM
|
0
|
0
|
316
|
POST
|
I created an extension to ArcMap (9.3.1) that employs a MapControl. I recently upgraded to ArcGIS Desktop 10 and found to my dismay that the MapControl - which resides in ESRI.ArcGIS.Controls library - now requires an Engine license. Setting aside my deep displeasure at this change in marketing strategy, my operative question is - how much do I have to spend to enable the MapControl so that I can upgrade my extension to run in ArcMap? I have had several conversations with ESRI's sales & marketing people and I'm still confused. It appears that if I purchase an EDN subscription I will receive the ArcGIS Engine SDK and I should be able to convert my 9.3.1 extension to 10.0. My problem is that the ESRI folks keep talking about "production level" licenses - assuming, I guess, that they think I am trying to create a stand alone app that will be available over the web. But, my program is an extension to ArcMap and will only be used within that environment - therefore the user has a ArcGIS Desktop license and should not need any additional licensing run to run my extension with its embedded MapControl? I would appreciate hearing from anyone who has had to convert a MapControl bearing tool, command or extension from 9.3.x to 10 and what it took license wise to make it work. Thanks. I work at Esri in development; I freely admit that I do not understand all the licensing details. I did find this statement on the "How to create a MapControl application" page (http://help.arcgis.com/en/sdk/10.0/arcobjects_net/conceptualhelp/index.html#//000100000008000000😞 Running the application with an ArcGIS Desktop license Since the application is set by default, it requires an ArcGIS Engine Runtime license. However, if you want it to run on a machine with ArcGIS Desktop (ArcView, ArcEditor, or ArcInfo), or to check for and consume a floating ArcGIS Desktop license, update the LicenseControl to verify the other licenses as well. Do the following steps to run the application with a license: Right-click the LicenseControl and choose Properties. The Properties dialog box appears. Select the check boxes of the licenses you want to use when the application runs. The application always uses the lowest level of licensing that is available. For example, if a machine has an ArcGIS Engine and ArcEditor license, the application uses the ArcGIS Engine license. If there are ArcView and ArcInfo floating licenses available and both of those options were selected in the LicenseControl, the application uses the ArcView license. ----- When it says 'set by default,' it means that the VisualStudio Esri wizard automatically sets up licensing for Engine. Melita
... View more
10-15-2010
04:20 PM
|
0
|
0
|
654
|
POST
|
I am working on an application where I want to change central meridian so that if the user is looking at data near the IDL, the data is in the center of the map and there isn't an issue where data must wrap around. I am adding the data to the feature class using standard central meridian = 0. I then get the dataset extent's and then setting the map's spatialreference central merian to the midpoint of the extent. I have tried a variety of simple things such as setting the same modified spatial reference to the map layers. I have removed and re-added the layers to the map. Is there a simple solution for this or do I need to retrieve each piece of geometry of each feature and somehow apply a transformation for the new central meridian? Also looking at the documentation for ILayer::putref_SpatialReference the Remarks say: This property is only used for map display, setting this property does not change the spatial reference of the layer's underlying data. The ArcGIS framework uses this propert to pass the spatial reference from the map to the layer in order to support on-the-fly projection. To me, this sounds like exactly what I want. I want to add the data to the feature class, change the map's spatial reference and see the data projected correctly. What am I missing? I load and display the world shape file (from the sample data) and this projects exactly like I would expect when changing the central meridian. I have tested this on 9.2 SP5 and 9.3.1 SP 2 on Solaris. Thanks, Gary Hi Gary, I can't understand what you're trying to do. It sounds to me like you're trying to change the coordinate system (spatial reference) of a layer/dataset without projecting it. I think you're on the right track that you just want to update the data frame's coordinate system. You want to set the central meridian of IMap::SpatialReference to the center of the area of interest. What coordinate systems will generally be used for the map and for your data layers? Melita
... View more
10-15-2010
04:00 PM
|
0
|
0
|
316
|
POST
|
Hi, Anyone please, can tell regarding the map projection. I have images of Moon, which is originally generated through Geographic lat/long, WGS 84 datum. I am working with ArcGIS 9.2. I worked applying the conversion factor of Moon ie 30.333 km is equal to 1 degree, in case of my applications. I try to reproject the image in Moon spheroid, it is done, I apply the flattening factor of the major and minor axis, I was very happy that I did it, when I check the projection it is showing moon spheroid, but in my application work the scale is not coming with respect to the Moon. And when I check the datum, it is showing unknown. So please tell me, is it not possible to project the images who were originally processed in Geographic Lat/long, WGS 84 datum to lunar projection (datum). I ll be very thankful to you. with regards, guneshwar gune.ishwar@gmail.com I think you are running into a known issue or two in ArcMap/ArcGIS. Map projections and datum transformations for vector data are handled by the projection engine library (pe.dll). Rasters use both pe.dll and another library. The other library may not be able to save a moon-based coordinate system in that particular raster format. What format is the data? (tiff, jpeg, GRID) If you're trying to measure features in ArcMap, I believe that it was hard-coding an earth ellipsoid when calculating the measurements. You may want to check out PIGWAD (http://webgis.wr.usgs.gov/) which has some tools and forums specifically about non-earth data. Melita
... View more
10-14-2010
11:40 AM
|
0
|
0
|
645
|
POST
|
Thanks for all the comments, feedback and help. I removed 'Class' from SpatialReferenceEnvironment and receive another COM exception: Retrieving the COM class factory for component with CLSID {7B5B7020-C4F6-11D1-BC92-0000F875BCCE} failed due to the following error: 80040111 ClassFactory cannot supply requested class (Exception from HRESULT: 0x80040111 (CLASS_E_CLASSNOTAVAILABLE)). I'm not a COM developer, so this is a little foreign to me. A bit more on the map I am using. I was handed a MXD file that has Virginia's map data (Danville area), and in order to track across the US, ESRI's North America Street Map data was also added. The map as previously indicated should be projected in the Virginia State Plane. I did change by PCS to esriSRProjCSType.esriSRProjCS_NAD1983SPCS_VASouthFT, but as I mentioned, I get the error mentioned above. If I can get past that error, that would be great. Is there something I have to do to put a wrapper around Arc Objects COM object? Thanks for the help. Bob Hi Bob, I tell people that I'm barely a programmer (I do enough for testing, but it sure isn't 'elegant') so I can't tell if you're using VB6 or VB.Net code, or maybe something else. For VB6, try Dim pSpatRefFact As SpatialReferenceEnvironment Set pSpatRefFact = New SpatialReferenceEnvironment and you also need to use Set pGCS = pSpatRefFact.CreateGeographicCoordinateSystem(enum) For VB.Net, try Dim t As Type = Type.GetTypeFromProgID("esriGeometry.SpatialReferenceEnvironment") Dim obj As System.Object = Activator.CreateInstance(t) Dim pSpatRefFact As ESRI.ArcGIS.Geometry.ISpatialReferenceFactory3 = obj Melita
... View more
09-29-2010
05:23 PM
|
0
|
0
|
981
|
POST
|
You're using the HARN PCS which probably isn't the VA State Plane that you want. Since you're needing to project your coordinates into the PCS of the map, then just get the spatial reference of the map instead of creating it using the spatial reference environment. This will make your code work no matter what spatial reference the map is in. You'll still need to create the GCS according to whatever system your input coordinates are in. Unless, of course, you're getting those from a feature class or something that also has a spatial reference (in which case, just get the SR from that instead of creating it). As for your error, try using SpatialReferenceEnvironment (without the Class on the end). If the sample projected point is in Pittsylvania or Danville area, then the pcs is Virginia South, using US survey feet. Could be based on NAD83 or NAD83 HARN. The 11 million value is the easting or X value. The PCS you have below is using meters, rather than feet. Try esriSRProjCS_NAD1983SPCS_VASouthFT or esriSRProjCS_NAD1983HARN_StatePlane_Virginia_South_FIPS_4502_Ft However, the lat/lon you have (42.234234, -79.234234) is in west New York state. Latitude values for very southern Virginia should be around 36.6. Some possible references are: Hitchhiker's Guide to coordinate systems http://edn.esri.com/index.cfm?fa=media.detail&media=54 2010 Esri Developer's Summit: Understanding and using the geometry ... http://proceedings.esri.com/library/userconf/devsummit10/tech/tech_58.html Understanding map projections and coordinate systems ($145, no programming) http://training.esri.com/acb2000/showdetl.cfm?DID=6&Product_ID=697 Melita
... View more
09-29-2010
12:20 PM
|
0
|
0
|
981
|
POST
|
Hello, I'm trying to transform a Point from DHDN to WGS84 using this Code: It seems to work, but the result is: x=-2.7588 ; y=-16.5578 I would expect somthing arount: 51 ; 7 Thanks a lot, Andreas Ruloffs viasecure Deutschland GmbH Hello Andreas, Your coordinates aren't in decimal degrees, so they must be in a projected coordinate system. I think the input points are using DHDN Germany 2: 31492. Melita
... View more
09-28-2010
04:31 AM
|
0
|
0
|
262
|
POST
|
When I open my Geodatabase Properties, the contents (General & Domain tabs) are not centered in the window and are, instead, offset towards the bottom-right corner of the properties window so I cannot view all of the items. Does anyone know why this is suddenly happening? This happens for all of my Geodatabases, by the way. Thanks! Please check out my post in this thread: http://forums.arcgis.com/threads/12258-Data-Frame-Properties-Box-Messed-Up-Arc10?p=36832#post36832 Hopefully, there's something in the links that will help you. Melita
... View more
09-21-2010
02:21 PM
|
0
|
0
|
265
|
POST
|
I am creating a map that will show radio coverage of up to 45 kilometers (buffer zone) range around particular towns in Mali, West Africa. I want to then do a clip to pull out all of the villages within the buffer zone ranges in order to calculate the total number of population in radio reception range. What would be the best projection to use keeping in mind my location and also the purpose of the map? Thanks in advance! Hello, If you're using 9.3 or 10, and you're buffering points, keep the point data in a geographic coordinate system. The geoprocessing buffer tool will then create 'geodetic'-based buffers. That is, the distances will be unaffected by being in a projected coordinate system. Melita
... View more
09-15-2010
01:02 PM
|
0
|
0
|
217
|
POST
|
As expected this issue returned after I installed the Desktop part of the ArcGIS 10 (Desktop, Engine, Server) Raster Format patch from http://resources.arcgis.com/content/patches-and-service-packs?fa=viewPatch&PID=17&MetaID=1648 I left ArcMap 10 open while editing the registry but had to then close and re-open ArcMap before seeing the workaround take effect. Anyone know an NIM bug number for this that we can use to track when it is fixed? - Graeme Hi Graeme, Possibly, NIM060238. However, its description says that upon using multiple ECW files (selecting a bunch of different rasters in ArcCatalog, not all are ecw), sooner or later the "invalid raster" error occurs. Close ArcMap/ArcCatalog and the files can be read again. The ECW displays upside down issue is NIM059863. Melita
... View more
09-01-2010
01:39 PM
|
0
|
0
|
865
|
POST
|
I am searching for a method that can take any set of geographic coordinates (world-wide) that constitue a polygon (stored in a pointCollection) with a defined geographic coordinate system (datum, ellipsoid etc) and calculate the Geodetic Surface Area in square metres based on the ellipsoid. I imagine that somewhere within ArcObjects suite this must exist, and would be very grateful to anyone who could point me in the right direction. Thanks. No, that functionality doesn't existing within ArcObjects. Methods are generally approximations and we've been comparing some of them this summer. You'll get reasonable answers just by projecting the polygon to an equal area projection, hopefully centered somewhere near the data. If necessarily, you may want to densify the polygon first. At 10, you can now write code to densify a polygon or polyline with points on a geodesic, loxodrome/rhumb line, great elliptic, or normal section: IPolycurve4 or IPolycurveGeodetic. Melita
... View more
08-16-2010
03:51 PM
|
0
|
0
|
898
|
POST
|
Hello, Does anyone know wich is the best geographic transformation to convert a raster from GCS_WGS_84to to ED_1950_UTM_Zone_32N? Thank you very much, Alessandro What is the data's extent? Or, what area are you interested in? If you have ArcGIS Desktop, look in the documentation folder and open the geographic_transformations.pdf file. Or it's here online: http://resources.arcgis.com/content/kbase?fa=articleShow&d=21327 Don't worry about the direction of a transformation. Generally, transformation convert from a older or local geographic coordinate system to a newer or more general coordinate system. Currently, all transformation can be applied in either direction and the software will handle it for you. Melita
... View more
08-13-2010
12:00 PM
|
0
|
0
|
555
|
POST
|
Melita. I can transform individual coords via Grid inQuest's GUI; in fact I did this manually for a small set of coords, appended the results to my original spreadsheet, created XY feature from this set, added to ArcMap and they plot exactly where I want them to. It's the conversion of Batch Coords that doesn't work for me. Set attached. Couldn't attach a .csv here, so added an .xls Thanks. Hi Marc, Hmmm, the only problem I hit is that the setup for a batch file with lat/lon input wants ellipsoidal heights. I set it to use the ID column! Here's what I got: 200265.66997,733823.81832,-53.716,Newlyn 200300.70257,733781.28443,-52.715,Newlyn 200310.16479,733829.14868,-51.715,Newlyn 200332.75046,733828.08217,-50.715,Newlyn 200337.75582,733868.72512,-49.715,Newlyn 200355.59868,733832.57778,-48.715,Newlyn 200364.98978,733813.55384,-47.715,Newlyn 200387.63967,733792.04441,-46.715,Newlyn 200412.40735,733749.99721,-45.714,Newlyn 200877.60236,733402.89597,-44.710,Newlyn 200931.57506,733194.10461,-43.710,Newlyn 201175.05237,733338.73290,-42.708,Newlyn 201152.79377,733324.91487,-41.708,Newlyn 201178.09471,733293.99534,-40.708,Newlyn 201187.59682,733299.12297,-39.708,Newlyn Here are my steps. I'm using v6.6.0 build 1313. File, Convert files. Select the excel file. (Text File Decoding Wizard starts) Click Next to use New Format. On Select Rows to Decode, I set it to row 2. Next. Coordinate Format: Geodetic. Next. Select Data Fields: Right click column 1 and select ellipsoidal height R-click 2 and select latitude R-click 3 and select longitude Next Geodetic Information: coordinate format: Projected (Eastings, Northings) (make sure it lists OSGB36 (OSTN02) in the projection section) Output File: I specified a text file, output.txt. Next. File format successfully defined. Finish the tool... I hope this is helpful, Melita
... View more
08-12-2010
10:06 AM
|
0
|
0
|
1487
|
POST
|
Hi. I'm hoping someone will entertain this query and apologies if it's been done to death. I have a set of GPS coordinates - points near the coastline. I want to tranform them to British National Grid (BNG) so I can display against some raster mapping of land. 1. My initial solution was to take the spreadsheet of coords, convert from degrees/decimal minutes to decimal degrees. Then use the Convert (files) function of Grid inQuest to transform from ETRS89 to BNG. Then create XY data. However, individual conversions work in Grid inQuest but every time I use the Convert (files) my results never produce a list in BNG. 2. I'm also attempting to use the Project function from Toolbox, however the Geographic Transformation option does not provide the tranformation I want, ETRS89 to BNG/OSGB36. Thanks. ESRI doesn't have the same transformation that the Grid InQuest tool does: OSTN02 and variants. You could use one of our OSGB_1936_To_WGS_1984_xx ones, but we don't have any for OSGB36 / ETRS89. I have the software but haven't tried using files with it. Can you post a sample row or two here? If your data is offshore, there's a possibility that Grid InQuest is treating it as out-of-range. I ran into that when working with the Irish grid file support. Can you convert one of those points via the GUI? Melita
... View more
08-11-2010
04:50 PM
|
0
|
0
|
1487
|
Title | Kudos | Posted |
---|---|---|
1 | 07-03-2019 08:56 AM | |
1 | 07-08-2013 01:27 PM | |
2 | 08-11-2023 10:21 AM | |
1 | 07-11-2011 09:31 AM | |
1 | 10-12-2012 09:49 AM |