Home
MAPBASIC utilities, September 1995
Contents
1. 3 16 4 Additional files required 3 16 5 Use nabo 3 16 6 Known bugs limitations 3 16 7 Remarks 3 16 8 Possible developments 3 16 9 Filename 3 16 10Purpose 3 16 11 Origin 3 16 12 Additional files required 3 16 13 Use 3 16 14 Known bugs limitations 3 17 IMPORT MULTIPLE MIF 3 17 1 Filename MAP_BAS1 DOC BMLarue 28 Sep 95 3 17 2 Purpose 3 17 3 Origin 3 17 4 Additional files required 3 17 5 Use 3 17 6 Known bugs limitations 3 17 7 Remarks 3 17 8 Possible developments 3 18 FIXED LENGTH ASCII IMPORT 3 18 1 FILENAME 3 18 2 DESCRIPTION 3 18 3 ORIGIN 3 18 4 USE 3 19 INTERSECTION OF 2 REGIONS 3 19 1 FILENAME 3 19 2 DESCRIPTION 3 19 3 ORIGIN 3 19 4 USE 3 20 DRAW LINES TO POINT 3 20 1 FILENAME 3 20 2 DESCRIPTION 3 20 3 ORIGIN 3 20 4 USE 3 21 CONNECT POINTS 3 21 1 FILENAME 3 21 2 DESCRIPTION 3 21 3 ORIGIN 3 21 4 USE 3 22 Overlay tables 3 22 1 FILE NAME 3 22 2 DESCRIPTION 3 22 3 ORIGIN 3 22 4 USE 3 22 5 Bugs Limitations MAP BAS1 DOC B MLarue 28 Sep 98 MAP_BAS1 DOC 1 INTRODUCTION 1 1 WHAT IS MAPINFO MapInfo is the mapping and medium range GIS software that SOPAC recommends for its member countries It offers an acceptable compromise between power and user friendliness As part of a European Union funded project it has been distributed to ACP member countries It has been as well adopted by other projects and is becoming a de facto standard in the Pacific region One
2. IDENTICAL WINDOWS 3 16 9 Filename ID_WIN 3 16 10 Purpose To copy the geographical and geometrical characteristics of a window and paste them to another one 3 16 11 Origin Developped at SOPAC 3 16 12 Additional files required 3 16 13 Use Same syntax as Copy and Paste Select one window then Copy f j MapInfo Eile Edit Objects Query Table Options Window Map Help UNTITLED Map ES UNTITLED Map E ii EEI Select the other and Paste IF gt MapInfo Se ee File Edit Objects Query Table Options Window Map Help Ey NTITLED Map 12 E Coy model 3 16 14 Known bugs limitations It might not work for non Earth documents 36 B MLarue 28 Sep 95 MAP_BAS1 DOC 3 17 IMPORT MULTIPLE MIF 3 17 1 Filename IMPORT1 MB 3 17 2 Purpose It allows to generate a text file with the names of the MIF files to import then it imports successively all the MIF files and saves them as Maplnfo standard format 3 17 3 Origin Developed at SOPAC 3 17 4 Additional files required A text file that contains the name and location of the MIF Files to import 3 17 5 Use When launched this utility opens a DOS window This is to let the user select the files to be imported 1 GO INTO THE PROPER DIRECTORY 2 TYPE DIR MIF B gt MYFILE TXT 3 TYPEEXIT TO RETURN TO MAP INFO Then the utility prompts the user to open the file select the one just created 3 17 6 Known bugs limitations The progress b
3. None 3 13 5 Use The utility prompts the user to choose a table to move 3 13 6 Known bugs limitations 3 13 7 Remarks 3 13 8 Possible developments 30 B M Larue 28 Sep 95 MAP BAS1DOC 3 14 MOVE SEVERAL TABLE BETWEEN 0 AND 360 3 14 1 Filename MV_WEST4 MB 3 14 2 Purpose Moves several tables listed in a Text file to be moved to fit between 0 and 360 3 14 3 Origin Developed at SOPAC 3 14 4 Additional files required None 3 14 5 Use The utility prompts the user to provide a text file with the names of the files including their complete path C TMP TEMP The extension TAB can be omitted All the tables will be closed and the utility opens the tables one by one It gives a control on which table is being moved in the message window 3 14 6 Known bugs limitations All the objects to be moved should not cross the 0 limit They should then be cut before the work is done This can be done by using the Menu gt Object gt Set Target then Menu gt Object gt Split command The tables are automatically packed before starting the work 3 14 7 Remarks 3 14 8 Possible developments 31 BM Larue 73 Sec 55 MAP_BAS1 DOC 3 15 BREAK REGION 3 15 1 Filename BRK_REG MB 3 15 2 Purpose Polygons are handled in Mapinfo as Region which can contain several Polygons Sometimes it is necessary to have only single polygon regions One way to do it is to be careful while creating the maps but some functions of MapInfo gener
4. Table Save Workspace Run MapBasic Program Cle Print Print Setup Save Window As If the user wants to launch another utility the following dialogue will appear It presents the contain of the data base a full name of the application its full path and a brief description To actually launch the application the user just either double click on the name of click on OK Choose Utility To Run ue Although a version of UTILITY database is distributed it will have to be edited by the user to fit the configuration on the computer The path will have to be modified to be most probably C MAPINFO UTILA The logical field MapBasic Program allows to launch as well true DOS Windows executable from the same dialogue box If the database is a DBF file then it can be read from ACCESS 3 1 3 Possible developments 1 An automatic update of the database 2 To pass parameters to applications 10 5M Larue 25 Sep 65 MAP_BAS DOC 3 2 OPEN TABLE 3 2 1 File Name OPEN TAB A similar utility OPEN_TAB makes use of the same capability of MapInfo to handle full path It makes use of the table DATA_ALL The structure is Field Field Name Type Width 1 TABLE NAME Character 25 2 FILE NAME Character 12 3 FILE PATH Character 60 4 DESC1 Character 60 5 DESC2 Character 60 6 DESC3 Character 60 As well the Choose Utility To Run 11 BM Laue 26 Seo sS MAP_BAS DOC COORD It prints various forms of the coo
5. report or a presentation 3 7 3 Origin Developped at SOPAC 3 7 4 Additional files required No Symbols necessary 3 7 5 Use The utility must be launched when front window a Mapper Then it will prompt the user with the actual size of the window in cm At this stage it is possible to change it A it keeps the content of the window identical at much as possible When not possible it will add information extend the map to keep the largest of the two dimensions It also removes the scroll bars so that the window will be filled and will not be changed during the export process This utility performs a similar task as PortLand from KGM 22 aM Larue 28 Sep 55 MAP_BAS t DOC Ss Mapinfo File Edit Objects Query Table Options Window Map Help Resize UNTITLED Map No scroll bar 3 7 6 Known bugs limitations It is meant to be used in conjunction with the Menu gt File gt Save Window As MapInfo suggests two formats one BitMap BMP raster the other Windows Meta File vector The two give similar results For more information see MapInfo Manual pp 275 276 BMP WMF The advantage of this utility as opposed to the re sizing while exporting the window is that it allows the user to control the content and the shape of the window 23 BM Larue 28 Sep 85 MAP_BAS1 DOC 3 8 TEST SYMBOLS 3 8 1 Filename TST_SYMB MB 3 8 2 Purpose Mapinfo provides capability to edit modify and change sy
6. 5 5 Known Bugs Limitations It works only with Polyline Polygon and Line not rectangles 19 OM Larue 25 5095 MAP_BAS1 DOC 3 6 READ A BITMAP 3 6 1 Filename RD_BMP 3 6 2 Purpose The utility reads an image saved as a Windows Bit Map file with a BMP extension and display it in a separate window 3 6 3 Origin Developped at SOPAC 3 6 4 Additional files required No Symbols necessary 3 6 5 Usage When Launched the utility prompts the user to open a BMP file then it displays it To do that it reads the size of the file then creates a TAB file It then opens the new map created It prints the size of the image in the MapInfo Message window MapInfo File Edit Objects Query Table Options Window Map S UNTITLED Example of a TAB file TABLE IVERSION 300 CHARSET WINDOWSLATINI DEFINITION TABLE FILE D DATA SAVO IMAGE SAVO3 BMP TYPE RASTER 0 0 0 0 LABEL Pri 392 0 392 0 LABEL PT 2 0 392 0 392 LABEL Pr 3 392 392 392 392 LABEL PT 4 CoorpSys NonEARTH UNITS MN UNITS MM 20 B MLarue 28 Sep 95 MAP_BAS1 DOC 3 6 6 Known bugs limitations It replaces an existing file with the same name without prompting It opens the image as IMAGE Table if an image of the same name exists there could be a conflict 21 B M Larue 28 Sep 55 MAP_BASt_DOC 3 7 RESIZE 3 7 1 File Name RESIZE1 MB 3 7 2 Purpose It re sizes a MapInfo window to prepare for it to be included in a
7. 8 6 Known bugs limitations 3 9 Vector components 3 9 1 Filename 3 9 2 Purpose 3 9 3 Origin 3 9 4 Additional files required 3 9 5 Use 3 9 6 Known bugs limitations 3 10 Add Arrows to Vectors 3 10 1 Filename 3 10 2 Purpose 3 10 3 Origin 3 10 4 Additional files required 3 10 5 Use 3 10 6 Known bugs limitations 3 11 EXPORT NODES 3 11 1 Filename 3 1 1 2 Purpose 3 11 3 Origin 3 11 4 Additional files required 3 11 5 Use 3 11 6 Knownbugs limitations 3 11 7 Remarks 3 11 8 Possible developments 28 Sep 95 MA_BAS1 DOC B MLarue 3 12 MOVE BY A VECTOR 3 12 1 Filename 3 12 2 Purpose 3 12 3 Origin 3 12 4 Additional files required 3 12 5 Use 3 12 6 Known bugs limitations 3 12 7 Remarks 3 12 8 Possible developments 3 13 Move One Table Between 0 and 360 3 13 1 Filename 3 13 2 Purpose 3 13 3 Origin 3 13 4 Additional files required 3 13 5 Use 3 13 6 Known bugs limitations 3 13 7 Remarks 3 13 8 Possible developments 28 Sep 95 3 14 MOVE SEVERAL TABLE BETWEEN 0 and 360 3 14 1 Filename 3 14 2 Purpose 3 14 3 Origin 3 14 4 Additional files required 3 14 5 Use 3 14 6 Known bugs limitations 3 14 7 Remarks 3 14 8 Possible developments 3 15 Break Region 3 15 1 Filename 3 15 2 Purpose 3 15 3 Origin 3 15 4 Additional files required 3 15 5 Use 3 15 6 Known bugs limitations 3 15 7 Remarks 3 15 8 Possible developments 3 16 CLEAN POLYGONS 3 16 1 Filename 3 16 2 Purpose 3 16 3 Origin
8. MAPBASIC UTILITIES Michel Larue SOPAC Secretariat September 1995 SOPAC Miscellaneous Report 206 This project was partly supported with funds provided by the Government of France TABLE OF CONTENTS 1 INTRODUCTION 1 1 What is MapInfo 1 2 Whatis MapBasic 1 3 Origin of the utilities 1 4 How to launch a MapBasic programme 1 5 General use of the applications 1 6 Other ways 1 7 STOP a MAPBASIC PROGRAM 1 8 Cosmetic layer 1 9 Additional files required 1 10 Distribution files LIST OF THE UTILITIES 2 1 SOPAC Utilities 2 2 KGM Utilities 2 3 MAPINFO 3 USER MANUAL 3 1 UTILITY 3 1 1 FileName 3 1 2 Use 3 1 3 Possible developments 3 2 OPEN TABLE 3 2 1 FileName 3 3 GRIDS 3 3 1 Filename 3 3 2 Purpose 3 3 3 Origin 3 3 4 Additional files required 3 4 JOINT POINTS 3 4 1 FILENAME 3 4 2 Purpose 3 4 3 Origin 3 4 4 Additional files required 3 4 5 Example B M Larue 3 4 6 Known bugs limitations 3 5 MAKE POINTS 3 5 1 FILENAME 3 5 2 Purpose 3 5 3 Origin 3 5 4 Additional required files 3 5 5 Known Bugs Limitations 3 6 READ A BITMAP 3 6 1 Filename 3 6 2 Purpose 3 6 3 Origin 3 6 4 Additional files required 3 6 5 Usage 3 6 6 Known bugs limitations 3 7 RESIZE 3 7 1 FileName 3 7 2 Purpose 3 7 3 Origin 3 7 4 Additional files required 3 7 5 Use 3 7 6 Known bugs limitations 3 8 TEST SYMBOLS 3 8 1 Filename 3 8 2 Purpose 3 8 3 Origin 3 8 4 Additional files required 3 8 5 Use 3
9. MBX extension Source files are stored with a MB extension Executable MBX files need MapInfo to be executed they are not stand alone applications There are several ways to launch a MapBasic programme e Ctri U e Menu Rile gt RUN MAPBASIC PROGRAMME e By pressing the Run Programme button in the Tools button Pad Eo Mapinfo Objects Query Table Options Window Map Help Coord New Table ITLE1 Map Open Table Ctrl 0 Open Worksp Close Table Close All Save Table Print Setup Save Window As Exit AlttF4 Run Utility Shift F3 Continental U S View Exit Utilities Pe ta hf os Se ition if the user has the Mapbasic compiler it is possible to run the application from MapBasic after having compiled the project 8M Larue 28 Sep 95 MAP_BAS1 DOC 1 5 GENERAL USE OF THE APPLICATIONS This applies at least for the utilities developed at SOPAC It adopts an Object Verb syntax The same way as in a word processor the user selects a text Object and then apply an action such as Bold Verb Many utilities are applied on the selection Select Button UE the Marquee Select Button EM Select If the selection is made from the Browser and the utility a mapping one a Mapping window has to be made active before launching the utility If this is not the case a message such as the following is issued It is not quite explicit In fact it means that the no object is selected ee atte eee Sa Se S
10. R MANUAL 3 1 UTILITY 3 1 1 File Name UTILITY MBX 3 1 2 Use Before we start there is a useful utility called UTILITY that can be used to help handling of the utilities One of the difficulties in Windows is to find where a particular file is in the sub directory tree Windows does remember one particular location and whenever an open file is performed the dialogue will be issued from this particular location It would be very handy to be able to store the full path to a particular file in this case a utility This program uses one capability of Maplnfo that is it is a data base Usually it is used for its geographical data but it can handle tabular data as well This utility makes use of a table with the following structure Field Field Name Type Width 1 UTIL_NAME Character 25 2 FILE NAME Character 12 3 FILE PATH Character 60 4 MAPBASIC Logical 1 5 DESC1 Character 60 6 DESC2 Character 60 7 DESC3 Character 60 8 FILES_NEED Character 60 9 ORIGIN Character 10 10 USE Memo 10 11 BUGS _ LIMIT Memo 10 12 NEXT Memo 10 When launched the utility adds a menu in the file system and opens this database in a hidden state Therefore the user cannot browse or edit it To do so it is necessary to open the table separately BM Larue 25 Sep 55 MAP_BAS DOC Mapinfo ja Edit Objects Query Table Options Window Map Tools Help New Table Open Table Open Workspace Close Table Close All Save Table Saye Copy As Revert
11. ar requires to have MapInfo in the forefront 3 17 7 Remarks Instead of the command DIR MIF B any other command can be used to generate the text file For instance in the case where the all files are not in one single directory DIR S B In any case it is possible to edit the file before opening it in Maplnfo to add or remove some of the files not to be imported The DOS part of the utility is just an example of one way to create a file list 3 17 8 Possible developments 37 BM Larue 23 Se0 35 MAP 8451 000 3 18 FIXED LENGTH ASCII IMPORT 3 18 1 FILE NAME fixed_im mbx 3 18 2 DESCRIPTION This App will import into a fixed length ASCII file into a Maplnfo table 3 18 3 ORIGIN KGM 3 18 4 USE There needs to be a temporary empty table named TAB_DEF open with the following structure i Modify Table Structure Small Integer Small Integer Character 10 The utility will store the characteristics of the columns to import in TAB_DEF If there is already one available the user is prompted to open it If none are already developed a standard one is in the utility directory The table will be emptied at the end of the use of the utility when Menu gt Fixed Length Import gt Exit Application As a result it will create a new table called NEW_TABLE The user will have to save it Only the values are imported There is no way to import decimal number so far In the case of decimal values they have to be entered either
12. as float or as integer If they come from a FORTRAN generated file some modification will have to be done later The resulting table is not mappable at this stage If some columns contain latitudes and longitudes the user will have to 1 Make the table Mappable Menu Table gt Table Maintenance gt Table Structure 2 Create points Menu Table gt Create Points 38 BM Larue 23 Seo 35 MAP_BAS1 DOC 3 19 INTERSECTION OF 2 REGIONS 3 19 1 FILE NAME int_reg mbx 3 19 2 DESCRIPTION This App will draw a region showing the intersection of two selected regions 3 19 3 ORIGIN KGM 3 19 4 USE Once launched the utility creates a menu The intersection is done in two steps 1 Accumulation of the region 2 Intersection of the selected regions The first step is initiated by starting the Begin Accumulation menu l Mapinfo l j ad UNTITLED Map al m Make Intersect Region Close Queries About Application Exit Application I f utility creates a temporary table map By selecting one object from the original map it is automatically copied in the temporary map I SS ah ee Esl File Edit Table Options Window Map Help IntRegion PZ SF UNTITLED Map i B 39 BM tara 28 Sep 95 MAP_BAS DOC The second by making the Menu Make Intersection active The result is put in a table called int_reg This utility shows how MapInfo can go toward a more comprehensive GIS at the cost of th
13. ate multiple polygons regions such as the Menu gt Objects gt Split There is therefore a need to break them into individual polygons or single polygon regions 3 15 3 Origin Developped at SOPAC 3 15 4 Additional files required None Mapinfo BA ile Edit Objects Query Table Options Window Map Help Break_Region UNTITLED Map Multiple Polygons Region Tr i Before 32 BM Larue 23 Sep 85 MAP_BAS DOC Ss E E Mapa eee eer vi l Edit Objects Query Table Options Window Map Help Break Region UNTITLED Map zh After 3 15 6 Known bugs limitations 3 15 7 Remarks 3 15 8 Possible developments 33 BM Larus 23 Sep 35 MAP_BAS1 DOC 3 16 CLEAN POLYGONS 3 16 1 Filename CLEAN1 MB 3 16 2 Purpose To clean adjacent polygons by putting the nodes at the same exact location 3 16 3 Origin Developped at SOPAC 3 16 4 Additional files required None 3 16 5 Use The user has to select two adjacent polygons The utility prompts for a minimum distance under which the two points should be considered identical Mapintfo Objects Query Table Options Window Map Help UNTITLE2 Map 1 Mapinto File Edit Objects Query Table Options Window Map CLEANI Tools B MLarue 28 Sep 95 3 16 6 Known bugs limitations It works actually only on two polygons 3 16 7 Remarks 3 16 8 Possible developments Extension to an unlimited number of polygons 35 MAP_BAS1 DOC 5M Larus 28 Seo MAP_BASt DOC
14. brief description of what they do how they work and what they produce Nevertheless some utilities are sufficiently self explanatory so they do not need to be documented The present report makes a summary of what is actually available It can also be used as a guide of the capabilities of Maplnfo Mapbasic Therefore a user in country can seek support to have some extension developed As a result it will contribute to a better use of the tool installed These utilities are full standalone programmes but each of them performs one single function They also give indications of ways and mean of programming with MapBasic Geographical Information system 7 2 ACP Africa Carribean and Pacific countries which signed the Lome covention and can receive funds from European Union B M Lane 28 Sop 95 MAP_BAS1 DOC 1 4 HOW TO LAUNCH A MAPBASIC PROGRAMME Mapbasic applications should not be confused with the MapBasic Window in MapInfo The Mapbasic Window is a Window inside MapInfo that records most of the commands that the user performs from the menu commands as macro that can be stored and invoked to perform similar action The MapBasic window is opened either by cliquing on the button or by Menu gt Options gt Show MapBasic window For more information on MapBasic windows see MapInfo reference manual p 294 From now on when we will refer to Mapbasic it will mean a Mapbasic application Mapbasic executable applications are files with a
15. ched A Dialogue appears At this time the user has to know which unit will be used 13 B M tarva 25 50 35 MAP_BAS1 DOC This file name will be only temporary as it is automatically placed in the sub directory where the utility has been launched from A third dialogue appears to set the projection system of the grid to create It is the standard Map Option Command dialogue See MapInfo manual p 215 this stage it is possible to completely customise the grid to be created Then when the grid is created the user is prompted to save it under another name and or another location Then the user is prompted to change the size and font of the text 14 BM Larva 25 Sep 55 MAP _8A51 DOC 5 s7 MapInfo UserGrid Map S File Edit Objects Query Table Options Window Map Help Grid click to the font change button kamsi again After re sizing the window the result looks like this 15 BM Larue 26 Sep 55 MAP_BAS1 DOC 16 aM Larus 28 Sep 55 MAP BASH DOC 3 4 JOINT POINTS 3 4 1 FILENAME JN_PNTS 3 4 2 Purpose Join selected points to form either a Polyline or a Polygon The result is put in the Cosmetic layer that becomes editable during the process It is the reverse function of MAKE POINTS 3 4 3 Origin Developped at SOPAC 3 4 4 Additional files required None 3 4 5 Example Starting situation A series of points in a table here untitled All or some of them are selected Then by choosing eith
16. e development of simple utilities fe MapInfo File Edit Objects Query Table Options Window Map Help Int Region int_reg UNTITLED Map ls 40 OM Larse 28 Sap 35 MAP_BASt DOC 3 20 DRAW LINES TO POINT 3 20 1 FILE NAME Instopnt mbx 3 20 2 DESCRIPTION This App will draw lines from a central point out to a table with objects within it 3 20 3 ORIGIN KGM 3 20 4 USE The utility will connect points from two tables with the same value in respective columns In our example below ID1 from UNTITLE1 will be matched with ID2 from UNTITLE2 gt Choose Table x 7 x roo ic i r _ Cale The result is show below The result is put in the cosmetic layer The utility first clears the cosmetic layer so any object such as autolabels will be erased As well the result will have to be stored before the utility is run again 41 MAP_BAS1 DOC 22 50 65 aM Larus o S t File Edit Objects Query Table Options a D c al 3 s oly CAE Li a Q zi z E gt UNTITLELUNTITLE Map MapInfo Options Window Map Help ala Edit UNTITLE1 UNTITLE2 Map Objects Query Table 42 B M Larue 28 Sep 95 MAP_BAS1 D0C 3 21 CONNECT POINTS 3 21 1 FILE NAME conndots mbx 3 21 2 DESCRIPTION This App will connect points from a tableusing either objects or lat long columns 3 21 3 ORIGIN KGM 3 21 4 USE It does about the same thing as Joint_pnts The main differe
17. eds the file ATAN2 MB in the appropriate directory for instance C MAPINFO to be re compiled 25 BM Lans 35 50 35 MAP_BAS1 DOC 3 10 ADD ARROWS TO VECTORS 3 10 1 Filename Vector3 MB 3 10 2 Purpose Add Arrows at the beginning at the end or at both ends of a vector If it is at the end it indicates the direction of a movement such as current 3 10 3 Origin Developped at SOPAC 3 10 4 Additional files required It needs the ARROWS FNT file It loads it automatically m2 033 34 435 206 W37 che 239 OHO wil A42 V43 Was W45 WMG P7 pis H9 A50 451 452 3 44 65 65 AST 158 G69 660 51 2 63 764 065 266 67 68 469 The arrows are defined for every 10 in direction This is a quick and dirty way of overcoming a limitation of MapInfo 3 10 5 Use The Menu proposes three possible actions End Begin and Double Arrows Although it is not obvious in MapInfo a line is a de facto vector at it has a beginning and an end 26 BM Larus 78 See 36 MAP_BAS1 DOC MapInfo Ee File Edit Objects Query Table Options Window Map Help anaes 5S NTE Mp ee Begin_arrow double arrow pail Exit Vector il About Vector mm Kal 3 10 6 Known bugs limitations Depending on the way the utility ends the Symbol file may not be updated at the end of the process This can be tested with the TST_SYMB utility 27 B M Larue 28 Sep 95 MAP BAS1DOC 3 11 EXPORT NODES 3 11 1 File
18. er Make_Polygone or Make Polyline it possible to make a Polygon respectively a Polyline in the Cosmetic layer MapInfo E i Eile Edit Objects Query Table Options Window Map Help mga q UNTITLED Map Make Polyline abou Mapinfo ile _Edit Objects Query _Table Options Window Map Help UNTITLED Map BM Larue 28 Seo 55 MAP_BAS DOC Mapinfo Objects Query Table Options Window Map Help Pa Exit UNTITLED Map 3 4 6 Known bugs limitations s The utility takes the points in the order they are E UNTITLED Map EISI in the table not in the selection Therefore one 5 4 can end with a situation that looks like the following The way to overcome this is to create two adjacent triangles and then combine them MapInfo Query Table Options Window Map Help Join points Set Target Ctrl T H Clear Target UNTITLED Map 1 Erase Ol2 Erase Outside D3 Overlay Nodes Unsmooth Convert to Regions i i Convert to Polylines Oo a 18 BM Larus 23 Seo sS MAP_BAS DOC 3 5 MAKE POINTS 3 5 1 FILENAME MK_PNTS 3 5 2 Purpose It extracts Points from the nodes of Polygons Polylines and Lines It is the reverse of JN_PNTS 3 5 3 Origin Developped at SOPAC 3 5 4 Additional required files No Symbols necessary Example Before Selected Object in UNTITLED After Created Points in Cosmetic Layer UNTITLED Map sunTmeD Map EE Z E 3
19. eral feature is that unless other mention the result of the operation is put into the Cosmetic layer The utilities work the same way as the Draw Autolabel feature in the standard MapInfo See MapInfo Manual p 97 The user must be very careful that Mapinfo does not prompt before erasing the cosmetic layer If the user closes the window then the content of the cosmetic layer will be lost See MapInfo manual p 30 for Clear Cosmetic objects Command and p 273 for Save Cosmetic Objects Command When objects are transferred in the cosmetic layers the table structure or its content is not transferred as well 1 9 ADDITIONAL FILES REQUIRED Some utilities require to have additional files such as a special symbol set Whenever necessary the standard MapInfo set is saved under the name BACKUP FNT and restored when exiting the utility The copying and saving of the FNT files can be done as well outside the utility Copying the file can be done in the file manager of windows It is advised to keep a copy of the standard MAPINFO FNT file either the original one or the one that the user chose to work with Then copying alternately renaming the customised symbols file to MAPINFO FNT Then in the MapBasic window of Maplnfo type Reload symbols This makes the new symbol set active 1 10 DISTRIBUTION FILES This report comes with a floppy disk It includes the utilities sources and executable files customised Symbols and some tables set for a standard in
20. erres EX The same message is issued when the table is not Packed lines in the table are m Empty This happens when objects have been deleted from a Eune ia map or lines deleted from the browser When the browser is id E opened some lines corresponding to the deleted object appear greyed To remove these lines the user has to ae Menu gt Table gt Maintenance gt Pack Table E E em B M Larue 26 Sep 55 MAP_BAS1 DOC To explain to the user how to use them we will take one example MAKE POINTS that extracts the nodes of a Polyline When the user Launch the utility then a New Menu apears in the Mapinfo Menu bar MapInfo File Edit Objects Query Table Options Window Map Help i UNTITLE1 Map yN y y V 5 y ACACA PO EPL OF ENN Paes x y re vs x x s N 2 5 2 N NS 7 5 S 5 wh S x Ca ae ACA x D UN voy NS sas NA COP AO PP OD LOOP PP OE SE SNS NAAN ANS vex COTS OO LEAP EAP DEEDS SONA SSS SUNY SNN SF OFF OOP AE OOOO LE A Q D vs ve tf 4 4 uN x eS vy vy vy se 7 x N tere Lf FF A Cale ae ae a ae ee ae a ae A x x y y AUN 0 4 8 C4 4 O48 y Coe 06 Of OOF x y LAUA E ae ae Oe ANAE ee ae ae s CRA a iN LAC sn CACA Uy The user selects one or several Polyline s Line s or Polyline s Select Make_ Points in the Menu Bar Mapi
21. mbol sets Symbols are the style of the Points put on a map Several sets of Symbols can be stored saved or changed This utility displays the set of symbols actually active in MapInfo 3 8 3 Origin Developped at SOPAC 3 8 4 Additional files required It uses the active Symbols 3 8 5 Use When launched it produces and open a map called TMP with the active symbols listed and numbered MapInfo Eile Edit Objects Query Table Options Window Map ae Jest Symbols TMP Map m2 033 84 35 206 Wi ce A2 3 4 a5 OH s47 aB 452 853 54 B55 456 A57 158 P2 963 764 a65 166 87 58 3 8 6 Known bugs limitations There can be a conflict if a map named TMP is already opened 24 BM tarvs 23 Seo Ss MAP_B8AS1 DOC 3 9 VECTOR COMPONENTS 3 9 1 Filename VECTOR2 MB 3 9 2 Purpose Measure the characteristics of a Line a vector 3 9 3 Origin Developped at SOPAC 3 9 4 Additional files required No Symbols necessary 3 9 5 Use Select a Line or a series of lines When done the components of the vector are mes in a message window MapInfo Fite Edit Objects Query Table Window Map aul Yector2 s UNTITLED Map xmin 1 1047 max 0 489724 ymin ONDIRAS 0 887631 Dx 0614971 Dy 0 207021 degree Selected Vector The azimuth that is given is in the sense of a wind direction or a ship heading 3 9 6 Known bugs limitations Therefore North is 0 East is 90 South 180 and West 270 It ne
22. name EXP_PNTS MB 3 11 2 Purpose It exports the coordinates of the nodes of Polygons Polylines and points to a Text file It also exports a third dimension taken from one column of the table 3 11 3 Origin Developed at SOPAC 3 1 1 4 Additional files required None 3 11 5 Use The utility prompts the user to choose successively a TXT file to export to a table to export from and a column of this table to be used as the third coordinate Z 3 11 6 Known bugs limitations 3 11 7 Remarks This utility is to be compared with EX_ASC from KGM 3 1 1 8 Possible developments 28 BM Larue 28 Seo 35 MAP_BAS1 DOC 3 12 MOVE BY A VECTOR 3 12 1 Filename MV_VECT1 MB 3 12 2 Purpose Move all the objects contained in a Table by a vector defined by its components Dx and Dy The latter parameters can be measured using VECTOR2 utility 3 12 3 Origin Developped at SOPAC 3 12 4 Additional files required None 3 12 5 Use The utility prompts for a table to be moved then for the components of the vector At this stage it indicates the unit of the map that has to be used 3 12 6 Known bugs limitations 3 12 7 Remarks 3 12 8 Possible developments 29 B MLarue 28 Sep 95 MAP_BAS1 DOC 3 13 MOVE ONE TABLE BETWEEN 0 AND 360 3 13 1 Filename MV_WEST3 3 13 2 Purpose The utility moves all the objects contained in a table to fit in the 0 360 window 3 13 3 Origin Developed at SOPAC 3 13 4 Additional files required
23. nce is that instead of working on a selection it works on entire table Also it has two options either it joints the points defines as objects or tit makes a line based on latitudes and longitudes of the points even ifthey are not on the map as object The table must be mappable to work 43 BM Larve 25 Sae 35 MAP_BAS1 OOC 3 22 OVERLAY TABLES 3 22 1 FILE NAME overlay mbx 3 22 2 DESCRIPTION This App will create an overlay of two tables 3 22 3 ORIGIN KGM 3 22 4 USE This is a typical GIS application Given two tables in the example rainfalls and slopes Slopes with values 100 200 300 400 500 from left to right and slopes with values 5 10 15 20 and 25 from bottom to top The utility creates a new table called OVERLAY with all the columns of the original tables It will then break the polygons in smaller ones each one with the two parameters of the original tables jasa i Maplinfo Eile Edit Objects Query Table Options Window Browse Help ID WIN Em4 MAINTA Y E RAINFALL Map SLOPE Map 3 22 5 Bugs Limitations Note that this program was not thoroughly tested so it is possible that problems are encountered with the program or Maplnfo itself A known problem is the fact that MapInfo is allocating memory without freeing it up again causing loss of memory every time you run it The only way to free this memory is exiting MapInfo completely 44 B MLarue 28 Sep 95 MAP_BAS1 DOC If you find out which stateme
24. nfo E Objects Query Table Options Window Map Help UNTITLE1 Map The utility then performs its task in this case it makes points at nodes location of the selected objects B M Larue 26 Sep 95 MAP_BAS DOC Mapinfo File Edit Objects Query Table Options Window Map Help JE UNTITLE1 Map COL as 1 6 OTHER There are four ways a utility can behave 1 It can create a new menu in MapInfo menu bar like in the example above 2 It can act directly without any warning nor intermediate step 3 It can add a menu somewhere else in MapInfo menu system Mapinfo e Edit Objects Query Table Options Window Map Help scl E UNTITLED Map 2 Open Table Open Workspace Close Table Close All Save Table Save Copy As Revert Table Save Workspace Print Print Setup Save Window As 4 Some MapInfo utilities create a Tool Mend and add new utilities Ix developed with the same options in this submenu B M Larue 28 Sep 95 MAP_BAS1 DOC EZ Mapinto File Edit we Query Table Eee Window Map f T ine q is al Fome Pane rae About t ScaleBar 1 7 STOP AMAPBASIC PROGRAM Utilities either leave MapInfo when they have performed their task or remain asleep Most of them have an exit option as well as an about which gives a brief description of the task performed If an error occurs the utility usually leaves MapInfo It has to be launched again 1 8 COSMETIC LAYER Another gen
25. nt maybe the overlap function is causing this let me know wil you Another problem you might stumble on is that the tables you are overlaying may not contain deleted records pack them first 45
26. of the reasons it has been adopted is its relative simplicity and the short learning curve associated The simplicity is at the cost of its power The successive updates address progressively the limitations but due to its philosophy it remains and will remain limited Some limitations are acceptable other have to be overcome Mapbasic offers solutions 1 2 WHAT Is MapBasic Mapbasic is a companion product of MapInfo that allows to develop either full stand alone applications such as EasyMap developed by ERSIS for FFA or small utilities It is a development language similar to a Basic language with functionalities to address geographical features 1 3 ORIGIN OF THE UTILITIES MapInfo comes off the shelf with some utilities such as a grid or a scale makers MapBasic comes also with some more utilities Along the time some developers at MapInfo Kevin Mahonet in particular wrote utilities to ease their work Most of those are accessible on INTERNET Unfortunately the South Pacific is not yet properly connected to the outside world as well as interconnected regionally In addition they are often designed for a specific use Some has also been developed at SOPAC They have been designed primarily by programmers for programmers Therefore they needed some cleaning before being distributed to end users The present set of utilities has been carefully checked and partially rewritten to be distributed A user manual is also provided which gives a
27. rdinates of a point When launched the utility makes a new Tool Picker button active in the main button pad MapInfo Eile Edit Object Query Table Options Window Map _ Help Coord gt UNTITLE1 Map latitude 0 44898 Decimal degrees gt r JE neira ld Degrees and Decimal Minutes longitude 1 29 12768 B lattude 1 33 3 677 the position of the point is printed It saias he standard Maplnfo display 12 BM Larue 73 Sa0 55 MAP_BAS DOC 3 3 GRID5 3 3 1 Filename GRID5 MBX 3 3 2 Purpose Create a customised Grid 3 3 3 Origin It is a SOPAC modified version of the GRID received with MAPINFO 3 3 4 Additional files required It makes use of a customised set of symbols called GRID FNT Before launching the utility make sure that the file is in your Mapinfo directory most likely C MAPINFO The symbols look like this m2 63 4 5 a WS CES OD CAD 41 M2 WS 4 A5 8H 247 45 49 60 461 452 463 54 5 66 A57 158 BY 60 61 CE2 3 G4 265 6 7 68 469 The utility makes use of the symbols 68 to 71 and the symbol 49 This drawing of the symbol set has been produced by a utility called TST_SYMB see under this name The main differences between this utility and the standard one distributed with MapInfo are e It places crosses instead of continuous lines e It automatically draw text around the map e It allows any projection system e It allows to use any unit available under MapInfo When laun
28. stallation B MLarue 28 Sep 95 MAP_BASDOC 2 LIST OF THE UTILITIES As already pointed out the utilities are coming from three main sources SOPAC MapInfo as standard distribution and Kevin Mahoney referenced as KGM utilities 2 1 SOPAC UTILITIES COORDINATES GRID5 JOINT POINTS MAKEPOINTS READBITMAP RESIZE WINDOW PRINT ACTIVE SYMBOLS VECTOR COMPONENTS ADD ARROWS TO VECTOR EXPORT NODES BREAK REGIONS IMPORT MULTIPLE MIF IDENTICAL WINDOWS OPEN TABLE FULL PATH 2 2 KGM UTILITIES AGGREGATE LINES AGGREGATE SYMBOLS ASCII EXPORT BUFFER SELECTION CLONE WINDOW CLOSE TABLE S COMBINE LAYERS CONNECT POINTS CUT STREETINFO FILES CUT STREETS IN REGION DDMMSS TO DECIMAL DEGREES DISTANCE TO OBJECTS DRAW LINES TO POINT FIND STREET INTERSECTION FIXED LENGTH ASCII IMPORT INTERSECTION OF 2 REGIONS LABEL STREETS AUTOMATICALLY LINEWITHIN MAKE SCREEN GRID OPEN MULTIPLE FILES OPTIMISE LOCATION OPTIMISE TABLE STRUCTURE POINT DISPERSION PROJECTIONS ETC RANDOM NUMBER GENERATOR REGION WITHIN RESIZE MAPPER FOR LAYOUT BM Larue 28 Sep 95 SELECTALL IN SCREEN SHADELAYER SORTTABLE STREET ALIASES STREET NAMES WITHIN UPDATE COLUMN VALUES UTILITY Launch a utility with Full path 2 3 MA PINFO AUTOCAD LINK ADD NODES GEOCODE GEOSCAN MAKESHIELD SYMBOL EDITOR INFOTABLE DDEEXAMPLE SCALEBAR OVERVIEW TEXTBOX MAP BAS1DOC BM Larue 28 Sap 95 MAP_BAS1DOC 3 USE
Download Pdf Manuals
Related Search
Related Contents
Ikelite S95 User's Manual お 知 ら せ トリオフィックス SETIS™ user manual Service Manual - Manuales de Service application mobile 36GB ディスクドライブ 使用手册 User manual Copyright © All rights reserved.
Failed to retrieve file