(Visual Basic for Applications) A subset of Visual Basic that provides a common language for customizing Microsoft applications.

learn more… | top users | synonyms

2
votes
0answers
105 views

How can I identify the pixel with the maximum value in a grid? [duplicate]

Possible Duplicate: How to find the locations of the highest values in a raster? How can I identify the pixel with the maximum value in a grid and get its coordinates? Any VBA code please?
15
votes
5answers
2k views

How can I find the farthest point from a set of existing points?

I have a set of points as a shapefile and I want to find (the coordinates) of a new point which will have the longest possible distance from each of the existing points. Is that possible? If yes, is ...
13
votes
2answers
3k views

How can I create weighted Thiessen polygons?

I have a point shape file and I create Thiessen (Voronoi) polygons programmatically using this scripting syntax: CreateThiessenPolygons_analysis (in_features, out_feature_class, fields_to_copy) ...
6
votes
2answers
481 views

How can I add a new field in a raster attribute table and loop through it?

I am working with an existing raster attribute table. I wonder how can I add a new field to it and then loop through the existing records to populate this new field? Of course I have done this many ...
3
votes
3answers
4k views

Polyline length calculation in ArcGIS 10/VB script

I used to run this length calc on my data in ArcGIS 8 and 9, and now it don't work in ArcGIS10. Can you tell me what I have done wrong? Dim dbllength as double Dim pcurve as icurve Set Pcurve = ...
0
votes
1answer
541 views

Going round in Circles..Buffering/ArcObjects/VBA

I've just started learning VBA and Arcobjects, and at the moment just playing around tyring to do different things. What i am trying to do is Click on a tool, and allow the user to put a point ...
3
votes
1answer
3k views

How to count and record the number of entities with the same name in the field calculator?

I have a question with ArcGIS 9.2. In an attribute table the column [name] includes the name of every place in this layer. Next to that (in columns [numbers]) there should be recorded how often a ...
4
votes
1answer
671 views

Visual Basic editor command icon is always disabled

I recently installed ArcGIS 9.3 in a PC with Windows 7.0. I opened an existing mxd file within which I developed some toolbars for a project. Each icon of a toolbar has behind it a VBA and ArcObjects ...
2
votes
1answer
390 views

How to use nested loops with cursors?

I use the following nested loops to read the first point feature of a dataset and the rest points in that dataset. Then read the second point feature of a dataset and the rest points in that dataset ...
3
votes
2answers
711 views

How to loop through an array of point features?

I have a set of point features and I wish to find the points that have common coordinates. Now I changed the code as shwon bewlo by using the IPoint and the compare method through a function. I have 2 ...
1
vote
2answers
187 views

How can I define the extent setting of environments programmatically in VBA?

I use the following line of code to define the extent setting of the environments GP.Extent = "144566.589424822 351191.130242809 145772.160224822 353810.742942809". However, I need to define it ...
3
votes
3answers
1k views

VB/Python script to populate a field with maximum value among other fields

I am using ArcGIS 10. I have a little experience with python but i feel that python in ArcGIS is slightly different. VB will work fine as well. Problem: I have n different columns called 'percent_1', ...
3
votes
1answer
205 views

getsubcurve from multipart polyline ArcGIS

I have code which analyzes multipart polylines (roads) from the beginning towards the end. The algorithm "moves along" the road. My multipart polylines include circular junctions and branches so they ...
4
votes
3answers
156 views

How do you navigate the ArcObjects OMDS?

How does everyone get round navigating the different OMD's I can work with single interfaces no problem, but when i have to use multiple interfaces I struggle to get my head round go through different ...
6
votes
1answer
8k views

Install VBA on ArcGIS 10

What is the complete recipe for installing VBA for ArcGIS 10 Desktop? The Esri help topic on this is incomplete. From the number of threads I found troubleshooting this I'm not the only one ...
1
vote
1answer
927 views

ArcGIS - VBA - How can I create perpendicular polylines of a specified length that retain the attributes of the original polylines

i, I am using ArcGIS 9.2 and am desperately trying to create perpendicular polylines to existing polylines that I have. I would want the perpendicular lines to cross the original lines at their ...
2
votes
1answer
1k views

Create Thiessen Polygons (Analysis) by defining an external feature boundary

Although this issue has been addressed in this post some months ago: Thiessen Polygon delineation within a Feature, the appropriate answer has not been given. So, new ideas are welcome. My question ...
2
votes
2answers
6k views

How to call a DLL file from VBA?

I have a DLL file that I have loaded and registered it in ArcGIS as a command icon. This icon launches a window where the user should do the following selections: an input file, a field name, select ...
1
vote
2answers
529 views

intersection between a geometry and a layer in Arcobjects VBA

i have to make an intersection between a polygon and a layer of parcels, the polygon used in the clip is not belonging to any layer and the result of this intersection should be all the parcels inside ...
2
votes
2answers
1k views

Copying Symbology between layers with different numbers of features

I am working on copying a layers symbology to a number of other layers which have the same geometry, table structure etc, etc but not the same number of features. I have a state wide layer and I ...
5
votes
1answer
2k views

How to save a layer file with a relative path

In VBA, how do you save a layer file (.lyr) with a relative path? I have some code that loads a shapefile into ArcMap but I am unsure of how I go about using this shapefile to then save a layer file ...
2
votes
1answer
505 views

Adding an ILayer to IMap in Arcgis Server 10

I wanted to add ILayer to IMap, i think it has been added but problem is that it does not display it on the website. I am running arcgis server 10, using visual web developer 2010 express edition ...
1
vote
0answers
200 views

vba code for algorithm to assign track file gps UTM coordinates (East Africa) to an overlay 5x5km grid cell

The GPS coordinates are temporarily imported in to an Access database from DNR Garmin files downloaded (as dbf file(s)), and then exported for mapping in AEJEE (ArcExplorer Education Edition). I need ...
4
votes
3answers
1k views

Add button to open URL in ArcMap 10

I want to be able to add a button into ArcGIS for my users, something like this: http://gis.utah.gov/code-visual-basic/vba-link-from-arcmap-to-google-maps Only, using VBA in ArcMap 10 now seems to ...
3
votes
1answer
1k views

How can I execute my custom model's tools in VB.Net?

I want to execute one of my tools (which I created with Model Builder). I can execute a built-in tool by this code, but when I change the tool name with Model Tool Names it doesn't work. I gathered ...
0
votes
1answer
728 views

Model Builder's VBscript

I use the Model builder to run my model and I have question Sub M() ' Create the Geoprocessor object Dim gp As Object Set gp = CreateObject("esriGeoprocessing.GPDispatch.1") ' Check out any ...
3
votes
2answers
551 views

Count the number of segments of a polygon based on the angles

I wish to count the number of segments of a polygon that has a length less than 25 meters when the angle between two vertices is not close to 180 degrees i.e. if the angle is between 178 to 182 ...
1
vote
1answer
835 views

Convert old ArcGIS 9 VBA tool to new Python script tool for ArcGIS 10

I have an ArcGIS .mxd file with an imbedded VBA script that is executed from a tool bar button. I would like to convert this VBA script tool to a python script tool for use in ArcGIS 10. Is that ...
2
votes
2answers
475 views

Create a dbf table by copying the structure of another dbf table

I have a dbf table and I wish to automatically create another dbf table with a different name but with exactly the same structure i.e.fields as the existing table. Is there any ready code in VBA and ...
1
vote
3answers
2k views

Calculate XY Coordinate with “CalculateField” tool

I used model builder to build a model which can calculate the XY coordinates and it's perfect! However, when I export it to VBscript and run it in VBA it crashes.... The error happens at ...
2
votes
2answers
653 views

How to creat a graph from a Field values (VBA_ArcObjects)

I have a combobox that shows all fields of a shapefile. I want to get these values programmatically in a label--Count, Minimum, Maximum, Sum, Mean, Standard Deviation--and populate a graph of the ...
1
vote
1answer
477 views

Using kriging with data in GDB

I have series of data in my GDB I am running the program under VBA and what I want to do is using the data by the tool Kriging. This is what I thought: First, Kriging needs data that must be a ...
2
votes
1answer
2k views

Call tools from ArcToolBox in VBA form

I am now looking for a code in VBA that can call Tools from ArcToolBox(The little red box) I have find a Arcobject code(I thought it's can run under VBA) but it's don't work! I have to delete the ...
3
votes
2answers
2k views

How to Open a Table, Convert it to ShapeFile & projecting the data using the X and Y

it's my first project using ArcObject, i create this interface : http://i118.photobucket.com/albums/o104/b_sara/Cap2-1.png i did programme the button "Parcourir" ( browse ) using a commonDialog, it ...
1
vote
0answers
122 views

Arcobjects - Properties Grid

Does anybody know a way, in VBA, to change the grid interval? For example: if my layout´s scale is 1:2000, my grid will have 200 meters interval and my layout´s scale is 1:5000, my grid will have 500 ...
2
votes
3answers
1k views

ArcObjects - Select record from table

I´ve a project in VBA but I hit a wall that I can't pass. What I want to do: I´ve a table (of parcels) with the fields: ID, Name, Area, Scale. For each Parcel there is a different scale! I input, in ...
3
votes
1answer
509 views

ArcObjects VBA: Setting Spatial Reference for Geometry Bag

Greetings, Within the ESRI SDK resources there is an example of combining polygons by use of a geometry bag. The following code appears: 'Define the spatial reference of the bag before adding ...
6
votes
2answers
2k views

Finding Nearest Feature Methods VB ArcObjects

Greetings, I have: (a) point feature class (b) polyline feature class I am trying to loop through the (a) point feature class to find the nearest feature from the (b) polyline feature class. Just ...
1
vote
0answers
49 views

How do I get non modal .dll things to work in ArcGIS 9 Education edition?

I dont know if I have installed it correctly on my computer. I think I need Non-Modal Forms Support in Visual Basic DLLs? and forcing VBA to load automatically in ArcGIS 9?
2
votes
2answers
858 views

Why is * .tlb not visible?

I've created a Visual Studio 08 Active X - MXCommands dll for a VBA button within ArcMap 9.3.1. I'm able to load and use the .tlb on my computer; however when I try it on my test computer the .tlb ...
2
votes
2answers
3k views

VBA to VB.NET (Visual Studio 10) Migration - ArcMap Focus

I will be migrating several VBA applications currently in ArcMap 9.3.1 to Visual Studio 10 in the near future, and wanted some feedback on the general migration steps listed below. I wanted to make ...
1
vote
0answers
266 views

topology rules for structuring topology data to get line feature as topoparent in topology graph

i Created topology graph of a polygon feature and i copied geometry of topology edges into line feature class,and topology nodes into point feature class i created topology layer containing ...
5
votes
1answer
868 views

How to create adjacency matrix of topology graph of arc map for shortest path?

I have created a topology graph of a polygon feature and I want to find the individual FIDS of the lines of the polygon. I want to construct an adjacency matrix to create the shortest path. How can I ...
1
vote
1answer
443 views

Getting ISpatialReference from ArcObject mapcontrol in VBA

I am working with ArcObjects and ESRI for the first time, and I am trying to do what is probably a simple task. I have a map control in VBA that is associated with a mxd. I have a table with XY ...
2
votes
3answers
994 views

Arc Objects and non-spatial table

I am a new Arc Objects user, with little ESRI experience. We are using VBA to create a spatial report on a Map Control using a mdb table. The mdb table contains a Lat and Long field, and this data is ...
1
vote
2answers
171 views

Accessing PAT,NAT of coverages using arcobjects

I want to access the polygon attribute table (PAT) and node attribute table (NAT) of an arcgis coverage using arcobjects VBA, is this possible?
3
votes
2answers
423 views

how to convert personal geodatabase feature class to coverage using arcobjects

how to convert personal geodatabase fatureclass to coverage using arcobjects with vba pls provide me any documentation or samples.
3
votes
4answers
787 views

VBA script for Incremental labeling in Field Calculator?

I have a shape file with a bunch of pipes in it. I would like to be able to label each pipe with "Pipe - X". X being the number in the row that the pipe falls on (Pipe - 1, Pipe - 2, Pipe - 3, etc). ...
2
votes
1answer
689 views

Disabling/overriding internal arcmap commands with vba

I am creating a template for ArcGis JTX. This is a mxd file, with a vba onload event handler which removes some functionality from vanilla ArcMap. I'm stumped on one problem: double clicking on a ...
1
vote
1answer
2k views

VBA field calculator: concatenating fields

I'm trying to get one column of text to move into another column that already has text. I DON'T want to replace it, I want the transferring text to be added to the already existing text in a shp file ...