Вы находитесь на странице: 1из 6

Registering Map To transfer a vector maps coordinates to a raster image: 1.

On the File menu, click Open and Raster Image file format. 2. Choose the raster image file and click Open. The Display/Register dialog box displays. 3. Click Register. The Image Registration dialog box displays. A preview of the raster image appears in the lower half of the dialog box. 4. Choose the Projection button to specify the images projection. If you do not set the projection, MapInfo Professional defaults to Longitude/Latitude or to the default table projection set in the Map Window Preferences. 5. To add control points, click the Add button to add a control point entry to the Control Points list. 6. Click the Pick from Map button and select a location in the Map window that matches a location in your raster image. MapInfo Professional updates the Map X and Map Y fields in the Edit Control Point dialog box with the new coordinates. Click OK to save this entry and close the dialog box. Digitizing with MapInfo Sometimes the only way to bring a map into MapInfo Professional is to trace the map by hand. Using MapInfos digitizing feature, you can trace the details of a paper map with a puck and a digitizing tablet and record the tracings as a vector image (object with geographic coordinates) that can then be displayed in MapInfo as a map layer. Since they are vector images, digitized maps allow you to use all of MapInfos powerful functionary with them. Digitized Maps vs. Raster Images While digitizing is a time-consuming process, it has some advantages over scanned raster images, particularly if you want to use the map for geographic analysis. Digitizing a map creates a vector image that is just like any other MapInfo map layer. Each feature you digitize becomes a map object that you can edit, move, customize, or attach data to. You can include as much detail as you want to trace from the paper map. A raster map, on the other hand, is simply a graphic image that is used for display purposes only. You cannot edit or attach data to it. It is used as a backdrop for other map layers. Its main advantage over digitizing is input speed. For more on raster images, see Chapter 19, Displaying Raster Images. Digitizer Setup To communicate the tracings on the paper map to MapInfo properly, you must provide some information about your map. In the Digitizer Setup dialog, you specify control points for your map, the map projection and appropriate map units, and configure the buttons on your digitizing puck. Choose Map > Digitizer Setup to begin. The Digitizer Setup dialog displays. Each part of the dialog is discussed below. Map Projection Maps are drawn using a particular projection, or distortion, of the earths surface to maintain the relationship of the curved earths features on a flat piece of paper. When you digitize a map using MapInfo, you must specify the projection so that MapInfo can take the maps distortion into consideration and maintain the correct relationship among the map features. You cannot change the projection after you have begun to digitize, so make sure you set it correctly now. Click the Projection button in the Digitizer Setup dialog to select a projection. In general, the projection is specified in the map legend. MapInfo supports a wide variety of projections. For aerial photographs, use Longitude/Latitude as the projection.

Map Units In addition to knowing the projection, you must specify the map units used for the coordinate system. For instance, a map in the Longitude/Latitude projection will show map coordinates in degrees. If you do not have coordinates for the map, you will need to digitize it as a non-earth map, which means points on the image will only be relative to each other, not to points on the earth. Create a non-earth map table first and display it in the active Map window. Specify the map units from the Map Units drop-down list in the dialog that matches the coordinate units on the paper map. Degrees will always be available for earth maps. In addition, other map units may be available if you have identified the map in a projection other than Longitude/Latitude. Entering Control Points For MapInfo to make a digitized copy of your paper map, it must be able to correctly interpret the location of the digitizing puck on the tablet as you trace the map. To do this, you must first set the parameters by specifying locational coordinates for several control points on the map. To set a control point, choose a point on the tablet and click a button on the puck. Type the coordinates that correspond to that point in the Digitizer Setup dialog. To add, edit, remove, or clear all control points, choose the appropriate button in the Digitizer Setup dialog. A dialog appears for each button to walk you through the steps. For instance, to add a control point, choose Add. The Pick Tablet Point dialog displays telling you to choose a point on the tablet and click a digitizer button. Now the Add Control Point dialog displays prompting you for a label (optional) and the map coordinates for the point. When you are through, click OK. Repeat this process for each control point you enter. Keep in mind that you must enter the coordinates in the units you specified in the Digitizer Setup dialog. If your map unit is in degrees, be sure to type in the coordinates as decimal degrees. For a discussion on converting degrees, minutes, and seconds to decimal degrees see Appendix 4, Converting Coordinates, in the MapInfo Reference. Editing Control Points To edit a control point, choose the point from the list of control points in the Digitizer Setup dialog and press the Edit button. The Edit Control Point dialog displays. Make the appropriate changes to the label or X and Y coordinates. Digitizing Your Map Once you have specified the control points, projection and map units of your map and have determined that the error for control points is acceptable, you are ready to digitize your map. To begin digitizing: 1. Make the Map window active and make a layer editable. 2. Choose any tool. 3. Choose Map > Change View to set the zoom of the Map window to be larger than the area of the map you are digitizing. This will keep the cursor in view during digitizing. 4. In the Change View dialog, specify the X and Y coordinates of a point that generally falls in the center of the map to be digitized. 5. Click OK. The Map window now shows roughly the same area as your paper map. If you have entered at least three control points in the Digitizer Setup dialog, digitizer mode should be on, and the digitizer cursor should appear in the Map window. 6. Press the D key to turn on digitizing mode. The cross hair cursor now becomes a cross hair. 7. Begin tracing the map

To create a .tab file from your Excel (.XLS or .XLSX) data: 1. In MapInfo Professional on the File menu, click Open to display the Open dialog box. 2. In the Files of Type list select (.XLS or .XLSX), navigate to your data, and click Open. 3. Select the worksheet you want in your MapInfo data table. Make sure that this data includes either postal codes or longitude/latitude coordinate values. The default data range for an Excel file is the entire worksheet. a. If you select the Use Row Above Selected Range for Column Titles check box, the default data range begins at A2 (row 2). b. If you clear the Use Row Above Selected Range for Column Titles check box, both the Named Range and Current Value fields revert to their previous values on the Entire Worksheet. 4. Click OK to display the Set Field Properties dialog box. This dialog box allows you to reset the name, type and properties of any field (column) that you import from the Excel table. The top of the Set Field Properties window shows the Fields (column names) and Type (character, date, etc.) from the Excel spreadsheet. When you select one of these fields, the Field Information box entries at the bottom allow you to specify the field name, data type, number of characters (for character and decimal fields) or number of decimals (for decimal fields only). 5. Click OK to convert the data to a MapInfo table (.tab) format. Now that you have converted your data, you can plot your data; see the next section to continue. Displaying your Access (.MDB or .ACCDB) Data To convert your Microsoft Access (.MDB or .ACCDB) data into a MapInfo Professional table: 1. Choose File > Open. The Open dialog box displays. 2. Choose Microsoft Access Database from the Files of type menu. The Access databases (.MDB or .ACCDB) for the specified location display. 3. Choose an Access database to open. If security is turned on, you will be prompted to give user and password information to open the database. 4. The Open Access Table dialog box displays the tables for the opened database. 5. Choose an Access table or tables to open. The table or tables are opened in MapInfo Professional. (Please note that for a table name with a space such as Order Details can be aved in MapInfo Professional but subsequently will not be visible to MapInfo Professional.) Opening Comma Delimited Files in MapInfo Professional You can export tables to comma delimited .csv text files. You can open .csv files from our File > Open dialog box as well. To open a comma delimited file: 1. From the File menu, click Open to display the Open dialog box. 2. From the Files of type box, select Comma delimited CSV (.csv). 3. Navigate to the folder that contains the file you want to open and click it to select it. 4. Click Open to display the Comma Delimited CSV Information dialog box. he Delimiter option buttons in this dialog box are disabled intentionally because commas are he only expected delimiters in this file format. 5. Select the File Character Set for this file from the drop-down list and select the Use First Line for Column Titles check box if applicable. 6. Click OK to open the file. When you export a file to a comma delimited (CSV) format, a Comma Delimited CSV Information dialog box displays. In this dialog box, you can

select a new delimiter, choose the file character set, and choose to use the first column in the file for column headings. When you have made your selections, click OK. To create a MAPINFO_MAPCATALOG manually: 1. If the RDBMS requires owners and users, then create the user MAPINFO with the PASSWORD MAPINFO in the specific database where the mappable tables are located. 2. Create the table MAPINFO_MAPCATALOG in the database. The Create Table statement must be equivalent to the following SQL Create Table statement. It is important that the structure of the table is exactly like this statement. The only substitution that can be made is for databases that support varChar or text data types; these data types can be substituted for the Char data type. 3. Create a unique index on the TABLENAME and the OWNERNAME, so only one table for each owner can be made mappable. 4. Grant Select privileges to all users on the MAPINFO_MAPCATALOG. This allows users to make tables mappable. The Update, Insert, and Delete privileges must be granted at the discretion of the database administrator. Prepare your Connection and Database To work with your DBMS data in MapInfo Professional, you need to set up your database connection by following the steps in the sections: 1. Creating a Data Source Connection There may be prerequisites, in addition to installing a driver, that you need to connect and work with a database. Each of the following sections provides details: Creating a Data Source Connection to SQL Server Creating a Data Source Connection to PostGIS on page 181 Creating a Data Source Connection to Oracle on page 182 When you connect to a data server, you will have two choices: to use windows authentication or to provide a username and password unique to the data server. Windows authentication is the username and password you use to log in to your network. Depending on how your database server is set up, you may only require your windows authentication to log in. Otherwise, you would provide a username and password that is unique to the server. Your database administrator will tell you whether or not you can use your windows authentication or a username and password specific to the server. 2. Creating a Map Catalog in the DBMS to Work with Data Your database administrator may need to grant you specific access privileges to the database to work with the data. The following section gives details: Before you Begin Creating a Map Catalog Table on page 191. 3. Making a DBMS Table Mappable to Display it on a Map Access your Data After setting up your database connection, you are ready to work with your data in MapInfo Professional, see Opening a DBMS Table in MapInfo Professional. For details, see: Working with SQL Server Tables Working with PostGIS Tables Working with Oracle Spatial Tables If your data includes spatial data, which can be columns holding X and Y values, such as Latitude/Longitude, or a column holding sptial data in the format specified by the database system. With no spatial information, you can work with your data in a table browser (a Browser window) in MapInfo Professional. If your data does not include coordinate information, then consider geocoding, adding the coordinate information, using a Pitney Bowes Software Inc. product, such as MapMarker or Spectrum.

Creating a Data Source Connection The first step to working with data in a DBMS is setting up a data source connection on your machine to the DBMS. This is necessary for a DBMS installed on to your machine or on the network. SQL Server and Post GIS require an Open Database Connectivity (ODBC) connection and Oracle Spatial requires an Oracle Call Interface (OCI) connection. You must have the ODBC driver or OCI installed on your machine before creating a data source connection. MapInfo Professional installs or updates Windows ODBC drivers if they are older than the version that MapInfo Professional supports. For non-Windows databases, such as Oracle and PostgreSQL with PostGIS, consult with your database administrator for information on how to obtain and install the driver provided with your database. Creating a Data Source Connection to SQL Server Before you begin, you need a SQL Server driver installed on your machine. Check with your database administrator to install the driver for your database. You need to know the SQL Server name, and the login ID and password if required. To create a new SQL Server data source connection: 1. From the File menu, select Open DBMS Connection. 2. If the Open DBMS Connection dialog box displays, select ODBC from the list and then click New. 3. In the Select Data Source dialog box, select either the File Data Source or the Machine Data Source tab and then click New. You can share the connection information for a file data source with other users on the network if they have the necessary drivers, because it is stored in a file. You cannot share the connection information for a machine data source, because it is stored in the registry on the local computer. 4. In the Create New Data Source wizard: a. Select the type of data source to create: User Data Source or System Data Source. Make a selection to display the description for it in the wizard. Click Next to continue. b. From the driver name list, select the SQL Server driver you have installed for the database and then click Next. c. Click Finish. 5. In the Create a New Data Source to SQL Server wizard set the following. If you are unsure of the settings to use for your database, consult with your database administrator. a. In the first screen provide the following information: Description Optionally, type a description if you plan on connecting to more than one database and would like a description for this connection. From the Server list either select from the list or type the name of the SQL Server to connect to. Click Next. b. In the next screen, select how SQL Server will verify the authenticity of the login ID. Optionally select to connect to SQL Server to obtain default settings for more configuration options. Click Next. c. Keep the default settings (check with your database administrator) and click Next. d. Keep the default settings (check with your database administrator) and click Finish. 6. In the ODBC Microsoft SQL Server Setup dialog box, click Test Data Source. 7. In the SQL Server ODBC Data Source Test dialog box, click OK. If there were errors, click OK to return to the ODBC Microsoft SQL Server Setup dialog box. Click Cancel to return to the Create a New Data Source to SQL Server wizard and use the Back button to view your settings and make changes. Return to step 5. 8. In the ODBC Microsoft SQL Server Setup dialog box, click OK. 9. In the Select Data Source dialog box, under the Machine Data Source tab, your new SQL Server connection displays in the list of available data source connections. Click OK.

10. In the SQL Server Login dialog box, type your login ID and password if required and click OK. You must now create a map catalog for the database, continue to Creating a Map Catalog Table Using EasyLoader Creating a Data Source Connection to Microsoft Access You can work with your Microsoft Access database from MapInfo Professional through an ODBC connection. Microsoft Access does not allow spatial data, but you can display in MapInfo Professional data that has X and Y coordinate values associated with it. Before you Begin Before you begin, you must have the Microsoft Access Driver installed on your machinethe driver is installed by default with your Microsoft Access. The driver is necessary for establishing an ODBC connection to the data source. To check that the driver is installed on your machine, run the ODBC Administrator: 1. Open the Control Panel; from the Start menu select Control Panel. 2. In the Control Panel, in the Classic View, select Administrative Tools and then Data Sources ODBC (ODBC). 3. In the Data Sources ODBC Administrator dialog box, select the User DSN tab. 4. In the list, locate and select the MS Access Database. Or, if you do not see this name, then under the Driver list look for Microsoft Access Driver (.mdb or .accdb). 5. Click Configure to ensure that it is properly set up. If the driver is not there, then click Add to check if the Access driver is installed. You may need to install the Microsoft Access drivers. These are included with Microsoft Access, Microsoft Office Professional, ODBC SDK, Visual C++, MapInfo Professional, or purchased separately.To verify if this is the required version of this driver, select the Drivers tab in the ODBC Administrator. Locate the MS Access Driver (.MDB or .ACCDB) and check that it is the latest version. To add a new Microsoft Access Data Source: 1. Run the ODBC Administrator. 2. Under the User DSN tab, click Add. 3. In the Create New Data Source wizard, select MS Access Driver (.MDB or .ACCDB) from the list and click Finish. 4. In the ODBC Microsoft Access Setup dialog box, in the Data Source Name box, type in a name for the data source. (This is the name that appears in the list when you connect from MapInfo Professional.) Click Select. 5. In the Select Database dialog box, select the Microsoft Access database you wish to use and then click OK. If you do not select a database for this data source, a prompt displays during the connection to do so. MapInfo Professional provides a sample Microsoft Access database.

Вам также может понравиться