MI Workaround for 5.0 Centroid Bug?
Greetings, I thought this would be a smaller problem than it is turning out to be. There is a bug in the MI 5.0 CentroidX, CentroidY and Centroid commands that returns, not the region centroid, but rather a corner point. I've noticed this both in region objects and in grids I've created (actually, they are region objects too). MI tech support says that the bug was fixed in a later version. Does anyone have suggestions for a workaround for this? I'm stiuck with version 5.0 for the time being. Thanks, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
RE: MI miles and kilometres
Message text written by "Lavoie, Claude" >What about this unit of measure the MIT students used to measure a bridge over the Charles River in Boston, Mass. (unit corresponding to the height of a fellow student)?< Wasn't that the "Smoot?" Steve [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Suggestions for Text in a Demo
Greetings, I've got the main part of my code working properly and would now like to create a demo. The demo will have a number of text boxes that come up at each step to explain what is happening. For example: Text Box: "In the next step we overlay a grid on the map." MapInfo: (remove text box and load grid table) New Text Box: "The program now appropriately colors each cell of the grid." MapInfo: (remove text box and run the code to color the cells of the grid) And so on. I can create a table for each text box, but that seems wasteful. Is there a better way to put all the text boxes into a single table and then control which ones are visible through MB? I'd also like to insert arrows at various points that point from the text box to items of interest. This is probably easy, but I haven't done any work with text at all, and probably just need to be steered in the right direction. Thanks & good luck, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
Suggestions for Text in MI Demo?
Greetings, I've got the main part of my code working properly and would now like to create a demo. The demo will have a number of text boxes that come up at each step to explain what is happening. For example: Text Box: "In the next step we overlay a grid on the map." MapInfo: (remove text box and load grid table) New Text Box: "The program now appropriately colors each cell of the grid." MapInfo: (remove text box and run the code to color the cells of the grid) And so on. I can create a table for each text box, but that seems wasteful. Is there a better way to put all the text boxes into a single table and then control which ones are visible through MB? I'd also like to insert arrows at various points that point from the text box to items of interest. This is probably easy, but I haven't done any work with text at all, and probably just need to be steered in the right direction. Thanks & good luck, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
SUM: Why does MI need program focus to save?
Greetings, This one turned out to be pretty simple: The problem -- While in the background, MapInfo would stop running at an attempt to periodically save data. I was using: If counter Mod 20 = 0 Then Commit table_name The solution -- Prevent the status bar from displaying. The status bar needs to have the computer's attention in order to proceed. If in the background, it patiently waits until you bring MI to the front. Here's the simple code: If counter Mod 20 = 0 Then Set ProgressBars Off Commit table_name Set ProgressBars On End If Thanks to the dozen or so kind folks who responded and helped me run the program. Good luck, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
Why does MI need program focus to save?
Greetings, My MB program collects information from about 20,000 locations -- a process that takes 24-48 hours to run. I save the data at various points to prevent total data loss with: If counter Mod 20 = 0 Then Commit table_name The program runs fine until it reaches this line (tries to save the table) at which point it stops if MI is not the application in focus. If I'm working on another program, the taskbar button will flash, and the program will resume running after I quickly go to MI and then back to the other program. This is annoying, but it was worse when I returned after letting the program run for 36 hours to find that it had spend almost all of that time waiting for MI to become the program in focus. This problem happens while running MI/MB 5.0 on a Windows NT station. Is there a workaround for this bug/feature? Thanks, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
Re: MI Do we want to create a MapInfo Newsgroup?
Message text written by Bill Thoen >A newsgroup is a wide open open mailing list, with the main difference being that all the mail resides on a server near you. [...] . You have to connect to an NNTP server (ask your ISP for the address of their news server) and you have access to literally zillions of email based discussion groups. The big GIS one is comp.infosystems.gis< Thanks for the GIS newsgroup address -- I didn't know about that one. I've been a fan of newsgroups for years (about 10?). I don't think access to newsgroups will be a problem, except maybe for those with corporate firewalls. If you have internet access, I think you have newsgroup access. I don't remember the website, but there is at least one that functions as a newsgroup reader. Many ISPs also provide a reader, although some (like CompuServe in my case) is pretty hard to use. The biggest advantage I see for a newsgroup is that it is "out there," waiting for you to come to it. If you leave town for a week and don't check/delete your e-mails, you won't return to find several hundred "MI..." messages waiting. They'll still be available, but at your convenience. If you read from several newsgroups, the messages from all of them patiently wait there for you to do read them. If you only have a passing interest in a topic, you can check in once a week (or whenever), scroll through the message titles and read the one or two that catch your interest. After some period of time (30 days?) the server dumps the messages, so at any point you wil only have access to the most recent (30 days?) worth of messages. Copies of older posting from many (all?) of the newsgroups are available at www.deja.com -- just search by keyword. The obvious disadvantage, as has already been stated, is that the newsgroups are completely public. This means we would see some amount of spam, pornographic ads, and other non-desirable off-topic posting. However, I don't think it would be a large amount for this proposed newsgroup. Some of the more technical newsgroups I frequently read have very little of this type of traffic. In general, the more technical and less juevenile the topic of the newsgroup, the less trash. However, off-topic trash is not our biggest worry. The biggest risk we face, in my opinion, is in losing the helpful and friendly character of the list. For some reason, newsgroups tend to me more impersonal. For example, it surprised me when Bill mentioned that the list had over 1000 subscribers. The posting mechanism we have in place now (post problem to list, direct-reply to original poster, post summary to list) is quite nice and would be difficult to implement in a newsgroup. The way newsgroups work, they lend themselves to continuing discussions where each poster adds a line or two and then posts for everyone to see. At least that's the character of most of the newsgroups I've been part of over the past decade. I'd hate to see the character of our list devolve to that of a typical newsgroup. When Bill originally asked the question, I was a solid "yes" vote. The more I think/write about it, however, the more I become a solid "undecided" vote. Good luck, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Summary -- Why do I get a .MBO file?
Greetings and thanks to all the kind folks who wrote. The problem: When I compile my code, MB now compiles it as a .MBO file. I don't know why it does that -- it was compiling fine (i.e., .MBX) before. The solution: Turns out to be pretty easy/basic. One of the responders wrapped up the answers: === MBO files are created in a number of different ways: 1) Use of sub procedures without identifying the first sub- procedure as main 2) Declaration of sub procedures within a program but without use of that procedure 3) Calling a sub-procedure within an mb has been declared but does not exist within that program There may be other reasons of which I am not aware, but hopefully one of these will help you. == My problem was actually #3. I was debugging my program by starting anew and copying small pieces to the new file. One of the procedures I copied called a function that I had not yet copied. Once I included the missing function, it compiled as .MBX. Thanks again and good luck! Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Summary -- Alias Variables in Map and Create Statements
Greetings and thanks for another problem solved, The problem: I'd like to use something similar to the Alias variable to use the Map command with a variable number of tables and the Create Table command with a variable number of columns. The solution: I followed the advice of Jacques Paris and it worked beautifully: Simply use the run command solution. For the map it could be RUN COMMAND "Map From "+StrTable_list as long as you respect the proper spacing (after from) and commas (in the list).. Trey Pattillo provided some further advice in consructing the strings: The thing that most often causes problems which I spotted instantly, been-there-more-than-once, is building your string. Use print or note/msgbox statements to view it with the *run command* commented out often helps. When you strTable_List is done it will read,table1,table2with a leading comma It doesn't matter which way you construct a *looped* string you will have either a leading or trailing comma left over. In you case, after the loop use strTable_List=mid$(strTable_List,2,len(strTable_List)) to remove the comma. Of course, I immediately looked up the "Run Command" statement in the reference book. Interestingly, the example given is exactly what I was trying to do! But, unless you know it exists, I'm not sure how you would bump into it. I'm still on a steep learning curve for MB, and finding "secrets" like the Run Command statement and the Alias variable are like finding gold! Thanks again and good luck, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Help!! Why do I get a .MBO file?
Greetings, And just when I thought I was getting the hang of MB/MI. When I compile my code, MB now compiles it as a .MBO file. I don't know why it does that -- it was compiling fine (i.e., .MBX) before. Then, all of a sudden, it starts compiling as .MBO. And, of course .MBO files don't run by themselves in MI. Is there something I entered in the code that makes do this? I've tried Save As, renaming the file, cutting and pasting into a new file, but it always comes out as .MBO. My other files still compile as .MBX. The help files and users manuals (both MI and MB, version 5.0) aren't helpful. Please help me get the .MBX files back. Thanks, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Alias Variables in Map and Create Statements
Greetings, Thanks to help from this list, I was able to tackle the Alias variable and use it in calling routines for multiple tables. Here's a bit of a twist. I'd like to do the same thing with the Map and Create Table commands.. For example, instead of: Map From Grid Table1, Table2, ..., TableN and Create Table table_name(Var1 Type1, Var2 Type2, ..., VarN TypeN) I'd like to do something like this: strTable_List = "" For i = 1 To N strTable_List = strTable_List + ", " + table_name_array(i) Next i and then use this string to open tables using the Map command. Then use a similar set-up to create tables. The situation I have is a variable number of tables to open and generally one column is needed in the created table for each opened table. It seems I *should* be able to do something like this, but these commands won't take alias variables (as far as I can tell, anyway). Thanks! Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Centroid...
Message text written by "David Eagle" >How do I change the location of a polygons centroid (probably defeats the idea of it being a centroid!) More specifically I have thematically created some bar graphs which once generated are not where I wish them to be. Anyone know how I can drag them into the right place?< Dave, Not real sure about the bar graphs, but I'd recommend you check to make sure the centroid is where you think it is. In at least one case (mine), a quirk in MI returns the lower left corner of a grid cell as the centroid (MI 5.0). This forces me to add half the cell width to the X and Y coordinated to get the real centroid. I didn't realize this until I forced a graphical output (line) that indicated where the reported centroid was. Good luck, Steve Riese PS I'm talking about grids created with the GRIDMAKR program that ships with MI. [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Matrix Inversion (again)
Greetings, Recently I asked about higher math functions in MB and received the recommendation to follow the "Numerical Recipies" book. I'm working now in VB6 and need some help in implementing the LUDCMP and LUBKSB functions. The recipies are in FORTRAN and Pascal, so I'm translating. Does anyone have these functions in basic? The key function I need now is a matrix inversion, and the two routines mentioned above should do this. Thanks! Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI SUM: Advanced Math Operations in MB
Greetings, A few days ago I asked about doing advanced mathematical operations in MapBasic. I received one reply and some additional help from colleagues at work. My needs were to do interpolation, sorting and matrix inversion, among others. [EMAIL PROTECTED] (sorry, I lost the name) recommended any of the "Numerical Recipes" books that are available. I had forgotten about these books and that was a welcome reminder. I then found, unfortunately, that MapBasic cannot handle multi-dimensional arrays. So much for inverting a matrix. Some office mates made the following suggestions: [1] Switch to ArcView and work in Map Object (which we have). [2] Work in MapX (which we don't have). [3] Work in VB and run MapInfo in a VB shell. [4] Do all operations manually off-line in Excel and/or Maple, MatLab, etc.. [5] Switch to SAS/GIS (which we have). MapX turned out to not be a feasible option because of expense (we are a dot-edu). I decided, instead on [3]. I should be able to write all of the advanced operations in VB and write a VB shell that will run both the VB and MI code. Thanks again for the suggestion (and the overall friendly and helpful atmosphere in the list). Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Advanced Math Operations
Greetings! I need to perform several math operations, the most difficult of which is probably a large matrix inversion. Are there any add-on packages to help do matrix operations? Thanks in advance, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Slash Screen
Message text written by Kenneth Laas >I remember seeing something about being able to change MapInfo's start-up splash screen to a customized BMP, something like a company logo. I feel kind of stupid asking this simple question, but I cannot figure it out for the life of me. Any help would be greatly appreciated.< I haven't tried it, but you might try finding the MapInfo BMP, and simply replacing it with your company logo (renamed, of course, as the same name name as the now deleted MapInfo Splash BMP). Unless MI has some checking procedure, it shouldn't recognize one BMP from another. Good luck, Steve [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Looking for Vector Data for Bosnia
Greetings, My project is in northern Bosnia. Are ther any existing files for that region? I need a fairly small scale (I'm working off of 1:50,000 maps). I tried the PSU maproom, which is a great service BTW, but their maps are a much larger scale. I'm looking for political boundaries, military boundaries during the war, terrain, vegetation, roads, and any other features that might be available. Thanks, Steve Oh, I'm working one a graduate student's budget :-) [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI One vs. Many Objects
Greetings, I tried an experiment and the results are not what I expected. I'd like to know if my results are an anomaly or should be expected. I have a procedure that examines each object (about 200) in a table for intersection with a given object. I tried this two ways: 1) Individual objects in the table are left as individual objects. 2) The objects are combined into one large object (and the table now has only one row). I expected the intersection detection routine to work faster in situation number 2, where there is only one object. In my trials, there is a slight improvement, but not much. Situation 1 actually is faster in some (few) cases. Any thoughts on this and the inner workings of the "Obj1 Intersects Obj2" function? I'm thinking that 200 objects in a table might not be enough to produce a significant difference, but that if there were, say, 2000 or more objects I might see a difference. Thanks, Steve [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Functions for Statistical Distributions
Greetings, Am making good progress on my project so far, thanks in no small part to the help I've received from this list. For the next phase of the project, I need to do some statistical analysis, and I wanted to see how much I should expect to do in MI/MB. I'd like to do everything in an MI/MB interactive session, if possible, because I use MI up front to collect data and MI at the end for output display. Would be nice to have one complete package. Here's what I need to do (after I use MI/MB to collect the data): 1. Determine a statistical distribution (e.g. Normal, Weibul) that best fits a given data set. I do this now visually in Excel by plotting the data against known distributions and selecting one that seems to fit well. I can then do a goodness of fit test, just to make sure the fit is statistically reasonable. Are there any functions available for MB that will allow me to: a) plot data in a simple x-y (scatter or line) chart and b) allow interactive adjustment of distribution parameters (e.g. mean, variance)? 2. Are there statistical functions available for MB that will return the CDF or PDF for a known distribution? I'm thinking here of the equivalent of the WEIBUL, EXPONDIST and NORMSINV functions (and others) in Excel. If the collective wisdom of the group says that this would be too hard to do in one package, I'll use MI/MB to collect the data, switch to Excel to do the statistical work and import the results back into MI/MB to produce the output. Thanks for any comments or suggestions, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Accessing Tables via Variable Names
Greetings, Sorry, if this is trivial, but I can't find an answer anywhere (in the documentation, that is) . I'd like to run the same procedure on several tables, without having to hard code a separate subroutuine or function specific for each table. The procedure works fine for one table at a time, but I need it to work for several tables. The part that's giving me problems (right now anyway) are lines like these: row_number = Table_Name.RowID table_object = Table_Name.obj When Table_Name is the actual name of the table, things work fine. How can I replace Table_Name with a (string?) variable so that the same code can be run on multiple tables? Thanks, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Detecting Intersecting Objects
Greetings, I have an intersting problem. I get different results from the following: A. If object_1 Intersects object_2 Then... and B. poly_line = IntersectNodes(object_1, object_2, INCL_ALL) Statement A evaluates TRUE (which is correct) but startement B *sometimes* returns an empty object. If displayed graphically, there is clearly an overlap. Is there a reason that the two intersection procedures would detect differently? More specifically, is there some trick to using the IntersectNodes function? and Is there another way to determine the point(s) of intersection (other than IntersectNodes, that is)? Thanks, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
RE: MI Raster to Vector Conversion
Message text written by "Juanse Barros J" >Steve riese How did you do the "mask out color process"?< Greetings, I have Picture Publisher 4.0 LE that can mask colors and delete the rest. It allows a mask of up to 8 colors. It further allows you to define a threshold (e.g. +/- 10%) for each color so you can capture colors that are similar. Thus, I can get most of the greens, blues, etc., with one cut operation (the selected colors are protected from the cut). Not sure how you would do this without the masking function. I got this program with a hand scanner I bought back in '94, when flatbed scanners were too expensive. I'm sure the "LE" stands for "limited edition" indicating that this is probably a basic feature that comes with most photo editing (not drawing) software. Good luck, Steve [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Follow-up to finding the nearest object.
Greetings, Thanks to everyone who wrote with suggestions on how to find the distance from a given point to the nearest object of a given type. The two basic solution approaches are: 1) Create a number of lines that radiate out from the known point and detect intersection. I implemented this using 36 lines (every 10 degrees). I used the GetEndpoint subroutine from the MapBasic library to find each lines' endpoint. After finding the closest intersection, I ran a more refined search from -10 degrees to +10 degrees from the original line (that produced the closest intersect). Results: this works nicely in situations in which the objects of interest are arranged "around" the known point. An example is a state boundary -- this would work well to find the distance from any point within a state to the closest state boundary. It does not work well when the objects are small and likely to fall in between the radiating lines. An example of this would be finding the closest city, assuming city objects are small relative to the distances between them. 2) Create buffers around the known point and detect intersection. Set upper and lower limits on the distance based on teh detection of intersection. Alter the size of the buffer using a binary search until you are within a given tolerance (difference between upper and lower limits). Although this method *seemed* to take longer to process than the radiating lines, it is sure to capture small objects or lines that would be parallel to the radiating lines. After experimentation, I used the second method. The following simple routine is the one I use to find the closest object to a given point. I've only tried it on linear objects and point objects, but it should work on regions as well. I'd appreciate any suggestions or comments. I've only used MB for a few weeks and welcome even seemingly trivial suggestions. Thanks and good luck, Steve Riese [EMAIL PROTECTED] '** Function Distance_to_Object(x1, y1 As Float) As Float 'Created By:Stephen R. Riese 'E-Mail:[EMAIL PROTECTED] 'Date: 1/6/00 'This function determines the distance from a known point '(x1, y1) to the nearest obect in a table. As it is written, it 'assumes that (x1, y1) is the center of a grid cell. If you don't 'use grid cells, you will need an object to replace "cell." 'These cells are objects in a table called "Grid." At this point 'in the program, the appropriate row in Grid is selected. 'The buffers created to detect intersection have 32 points. 'I use meters and a measurement within 2 meters is close enough. 'The variables "lower" and "upper" are the bounds on the binary search. Dim x2, x_intercept, y2, y_intercept, dist As Float, feature_object, intersection, cell, cell_buffer As Object, row_number, short_row As SmallInt, lower, radius, upper, difference As Integer, close_enough, intersect As Logical close_enough = FALSE lower = 0 'starting lower limit radius = 1 'starting "guess" value upper = 5 'arbitrary upper limit cell = Grid.obj Do While close_enough = FALSE cell_buffer = Buffer(cell, 32, radius, "m") 'creates buffer object ' ' leave these lines in to show what's going on graphically ' Insert Into Grid (Obj) ' Values (cell_buffer) ' Fetch First From Object_Table intersect = FALSE Do While Not EOT(Object_Table) 'check each object in the table row_number = Object_Table.RowID feature_object = Object_Table.obj If cell_buffer Intersects feature_object Then 'if intersects then subtract upper = radius 'set new upper limit radius = radius - (radius - lower)/2 'new "guess" Fetch Last From Object_Table intersect = TRUE End If Fetch Next From Object_Table Loop If intersect = FALSE Then lower = radius 'set new lower limit radius = radius + (upper - radius)/2 '
MI Raster to Vector Conversion
Greetings, I have JPEG images of 1:50,000 topographic maps. From these, I need to extract feature objects (roads, rivers, buildings, etc.). I can mask out colors and save different copies (e.g., save a copy with only green to represent trees), but how do I proceed to convert these green areas into vector objects? I've looked through the MI/MB documentation, but couldn't find anything. The area I've got is about 40km x 50km so, naturally I'm not looking forward to manually coding the points! Any help or suggestions? Thanks, Steve Riese [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]
MI Looking for Nearest Object Distance Functions
Greetings, I'm new to MapInfo/MapBasic and this list server. I'm looking for a function that will return the distance from a given point to the nearest object of a certain type. For example, from point (x, y) to the nearest house (point object), road or river (linear object) or nearest forrest (area object). All of the functions I've come across give the distance between two known points. I need to find the closest object first (e.g., which house or river is closest -- hard to do) and then determine the distance (easy to do). Is there some way to avoid an exhaustive search? I need to make tens of thousands of these calculations, each one selecting the nearest of up to hundreds of similar objects. In addition, each linear and area object are defined by two or more points. I assume I'll need to determine which point within each of these objects is closest to the known (x, y) point. Thanks for any help you can provide and Happy New Year! [EMAIL PROTECTED] -- To unsubscribe from this list, send e-mail to [EMAIL PROTECTED] and put "unsubscribe MAPINFO-L" in the message body, or contact [EMAIL PROTECTED]