|
POST
|
Have you tried using the display transformation object? It's available through IScreenDisplay.DisplayTransformation. It may give you what you're looking for.
... View more
02-25-2011
09:16 AM
|
0
|
0
|
1765
|
|
POST
|
You can't. ArcObjects are not backwards compatible. Your application can only run on machines that have the same version you compiled against (or higher in most cases).
... View more
02-25-2011
05:51 AM
|
0
|
0
|
568
|
|
POST
|
Yeah, the forums ain't what they used to be... Are you printing from data view or page layout view? If you don't change the form id, does it print at the correct scale? What happens if you go into the page properties in ArcMap and select A3, then run your code with the A3 form id value?
... View more
02-24-2011
11:07 AM
|
0
|
0
|
1041
|
|
POST
|
The names of the special fields are given by the IFeatureClass interface properties AreaField, LengthField, OIDFieldName, and ShapeFieldName.
... View more
02-24-2011
10:30 AM
|
0
|
0
|
1021
|
|
POST
|
It looks like you're using VBA or VB6. If so, you usually need to use Set when assigning object values. Also, you'll want to be sure that the feature class you're referencing is inside a feature dataset or its FeatureDataset property will be Nothing. Your current code will error out if that's the case. EDIT: Another possible thing to consider. You may need to use a dataset name object that comes from the workspace you're exporting into. It may also be required that this feature dataset already exist in that workspace. The exporter probably will not create it for you.
... View more
02-17-2011
10:18 AM
|
0
|
0
|
1165
|
|
POST
|
'pFeatureClassName.FeatureDatasetName = pFC.FeatureDataset I don't know that I've ever tried it but this line looks like a type mismatch. A dataset name object is required, not a dataset. You can get the dataset name object from the workspace's DatasetNames. You might also be able to use the name object from the dataset.
... View more
02-17-2011
09:59 AM
|
0
|
0
|
1165
|
|
POST
|
You can put the controls on separate forms with no problems. You will have to set the buddy control property through code instead of through the designer. For instance, if you have Form1 that contains a map control named AxMapControl1 and Form2 which contains a TOC control named axTocControl1 then this is what the code would look like. axTOCControl1.SetBuddyControl(Form1.AxMapControl1) You would need to call this code prior to showing Form2 (like in the form's Load event).
... View more
02-14-2011
04:38 AM
|
0
|
0
|
1847
|
|
POST
|
Using a point as a selection geometry is not your best bet. If you were selecting polygons then it wouldn't be much of a problem but to select lines or points the point coordinates must match exactly or nothing will be returned. For instance, if the coords of your point are 1.0, 1.0 and the nearest point on the line you're trying to select has coords 1.00000001, 1.00000001 then it won't select it because those points aren't the same. Try using a small tolerance to buffer your point and use the resulting buffer polygon as your search geometry. I would recommend using ArcMap's selection tolerance to buffer your point. You can use ITopologicalOperator to buffer the point and use IMxDocument.SearchTolerance to get your buffer radius. Note that SearchTolerance returns a value in map units, so if the map units differ from the units specified by the query layer's coordinate system you'll need to convert (use IUnitConverter interface).
... View more
02-10-2011
04:05 AM
|
0
|
0
|
2341
|
|
POST
|
Sounds like a spatial reference issue. If your code that performs the spatial query is not accounting for differences in coordinate systems then you may get incorrect query results. An example of how this can happen is this: your map's coordinate system is different than that of the layer you're querying. Your code takes an envelope sketched by the user as the query geometry. That envelope will have the same coordinate system as the map so if you don't project that envelope into the layer's coordinate system you may get incorrect results. As for deploying to other computers - you can only deploy to computers that are running the same version of ArcGIS (including service pack) as the computer on which you compiled the code. In some cases (but not all) you can deploy to computers that are running a higher version.
... View more
02-09-2011
11:34 AM
|
0
|
0
|
2341
|
|
POST
|
You're concatenating your query string incorrectly: query1 = "Month([Maint_Date1]) = " & UserInput1 & " And Year([Maint_Date1]) = " & UserInput2 A good way to debug this sort of thing is to display the string in a message box or print it to the Debug window. You can also step through the code with the debugger and examine the variable's value after executing that line of code. This will show you exactly what your query string is. As for adding the values to the combobox, don't try to have your query return the parsed date values. Just have it return the whole date then parse the date for the pieces you want using VB's date functions. I'm pretty sure the names of VB's date functions are MONTH, DAY, and YEAR.
... View more
02-09-2011
09:33 AM
|
0
|
0
|
2037
|
|
POST
|
The first part of my post was explaining why your code wasn't working. The last statement was saying you didn't need to do any of that and to use the IApplication methods. m_app is your IApplication reference. It has a Save and SaveAs method that you can call. There's no need to use IMapDocument at all.
... View more
02-09-2011
04:06 AM
|
0
|
0
|
378
|
|
POST
|
While there are classes in the ArcObjects model that you can't create yourself, it appears that the FeatureClassName class isn't one of them. Your code should be fine. Make sure you have all of the appropriate library references added to your project. As far as I know, ESRI.ArcGIS.Geodatabase and ESRI.ArcGIS.System are required but there may be others (check the dev help).
... View more
02-07-2011
07:50 AM
|
0
|
0
|
1730
|
|
POST
|
I haven't tested this yet but I believe Access supports the MONTH, DAY, and YEAR functions. Your query would look something like this: query1 = "MONTH([FieldName]) = 4"
... View more
02-04-2011
04:15 AM
|
1
|
0
|
2037
|
|
POST
|
The error means that the FeatureClassName class does not have a public constructor, meaning that you cannot create a new instance of the class. You obtain a reference to this type of object from another class which is capable of accessing the private constructor and returning an instance of the class to you. In your particular case, one way to get the reference you're looking for is through IDataset.FullName.
... View more
02-03-2011
11:49 AM
|
0
|
0
|
1730
|
|
POST
|
No, they are not the same. IEditEvents is the event interface for the ArcMap Editor. It's events fire anytime the appropriate actions are executed using the Editor. IWorkspaceEditEvents is the event interface for workspaces. It's events fire anytime the appropriate actions are executed against the specific workspace it is being used in conjunction with. If you are editing a particular workspace with the ArcMap Editor, then the events on the IEditEvents interface should fire the same as the events for IWorkspaceEditEvents setup to listen on that same workspace. If you have IWorkspaceEditEvents setup to listen to workspace "A" and the Editor is set to edit workspace "B" then the two sets of events will not be synchronous as your listeners will not be listening to the same workspace.
... View more
02-03-2011
04:40 AM
|
0
|
0
|
408
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 06-20-2014 05:29 AM | |
| 1 | 02-01-2011 04:18 AM | |
| 1 | 02-04-2011 04:15 AM | |
| 1 | 01-17-2014 03:57 AM | |
| 1 | 10-07-2010 07:37 AM |
| Online Status |
Offline
|
| Date Last Visited |
11-11-2020
02:23 AM
|