distribmapx

16
Chapter Chapter 16: Distributing Your MapX Application Distributing Your MapX Application The MapX product you have purchased from MapInfo is a developer's kit. It contains the MapX OCX, sample programs, an on-line help system, sample maps and geosets, and various utilities and other support files. This chapter deals with distributing your MapX application(s) to your customers. Please be reminded that you must purchase a Use License (i.e., seat) as evidenced by a MapInfo License certificate for each user of each application that you distribute with MapX functionality as described in the MapInfo Standard License/Development Environments, which is included in your product packaging. MapX Customer Installation Installing the MapX OCX Installing Support for Spatial Server Access Installing Raster Format Handlers Installing Maps and Geosets Adding Keys to the Windows Registry Passing in the MapX license String Redistributing Your MapX Application With MrSID 16

Upload: abuzarshazli

Post on 21-Oct-2015

17 views

Category:

Documents


1 download

DESCRIPTION

mapx

TRANSCRIPT

Page 1: DistribMapX

Chapter

➤ MapX Customer Installation

➤ Installing the MapX OCX

➤ Installing Support for Spatial Server Access

➤ Installing Raster Format Handlers

➤ Installing Maps and Geosets

➤ Adding Keys to the Windows Registry

➤ Passing in the MapX license String

➤ Redistributing Your MapX Application With MrSID

16

Chapter 16: Distributing Your MapX Application

Distributing Your MapX ApplicationThe MapX product you have purchased from

MapInfo is a developer's kit. It contains the MapX

OCX, sample programs, an on-line help system,

sample maps and geosets, and various utilities and

other support files. This chapter deals with

distributing your MapX application(s) to your

customers. Please be reminded that you must

purchase a Use License (i.e., seat) as evidenced by a

MapInfo License certificate for each user of each

application that you distribute with MapX

functionality as described in the MapInfo Standard

License/Development Environments, which is

included in your product packaging.

Page 2: DistribMapX

Chapter 16: Distributing Your MapX Application

MapX Customer InstallationProviding MapX Control (i.e. the piece of MapX that needs to be distributed within your

applications in order for them to work properly) in your MapX applications can be a

difficult task for the inexperienced programmer due to the high number of dependent files

and their complex structure. Therefore, MapInfo Corporation has begun automating the

distribution process. Basically, there are two methods of distributing the MapX Control

with your MapX applications. They are:

• Use the MapX OCX Installer that is provided on the MapX CD. This is the easiest method of distribution as it entails very little effort on the part of a MapX developer because certain procedures and tasks are automated.

• Integrate MapX control at runtime within the application you wish to distribute. This method of distribution is labor intensive and requires a substantial level of detail orientation, but provides programmers with the highest degree of control and customizing capabilities possible.

Using the MapX OCX Installer to Distribute the MapX ControlBasically there are only two steps needed to provide Map Control via the OCX Installer.

They are:

1. Select the MapX OCX Installer files located in [CD]\MapXtras\MapXRuntime on. This will automatically install the MapX mapping engine and the Geoset Manager. The default installation location is: Program Files\Common Files\MapX Common.

2. Make sure all licensing agreements with MapInfo Corporation and data providers are appropriately adhered to.

Example of Using the MapX OCX Installer MapXOcxPath = SRCDISK ^ MAPX_OCX_CD_PATH;

// launch the MapXocx setup

if (Is(FILE_EXISTS, MapXOcxPath ^ "setup.exe")) then

// Display a message to the user about us setting up the DAOSdShowMsg (@MSG_OCX_MESSAGE, TRUE);

ChangeDirectory(MapXOcxPath );

LaunchAppAndWait(MapXOcxPath^"setup.exe","",WAIT)

216 MapInfo MapX Developer Guide v4.5

Page 3: DistribMapX

MapX Customer Installation

// IMPORTANT NOTE: If using the Software Copy Protected (SCP) version of the MapX OCX Installer, use the following line instead.

// LaunchAppAndWait(MapXOcxPath^"setup.exe","MAPXSCP",WAIT)// Passing the argument "MAPXSCP" with force the SCP version

of the OCX to get installed.

// Done setting up, remove sessageSdShowMsg (@MSG_OCX_MESSAGE, FALSE);

endif;

Files Installed Automatically with the Installer OCXThese files are automatically installed when the OCX Installer method of adding Map

Control is used. These files are installed to:

C:\Program Files\Common Files\MapInfo Shared\MapX Common\

mdatasetint.tlb MMapXColumnInfo.dll mirdbspatialRes.dll

AllTypeRes.dll ColLookupSystem.dll CommandProcessor.dll

CommandProcessorRes.dll COMPILER.DLL COORDSYS.DLL

CoordSysRes.dll CustomProperties.dll DAENGINE.DLL

DAEngineRes.dll DBINFO.DLL DBInfoRes.dll

DBLAYER.DLL DBLayerRes.dll ExprPacket.dll

ExprPacketCreator.dll ExprPacketCreatorRes.dll ExprPacketRes.dll

FcnInfoServer.dll FcnInfoServerres.dll GEO.DLL

GeoObject.dll GeoObjectRes.dll GEOSET.DLL

GeosetManager40.exe GeosetManagerIntl40.dll GeosetRes.dll

LEGEND.DLL LegendRes.dll LEXER.DLL

LEXERRES.DLL MapBasicInternalFcn.dll MapBasicInternalFcnres.dll

MAPINFOW.PRJ MAPPER.DLL MapperRes.dll

MAPX.ABB MAPX.PEN METADATA.DLL

MIDLG40.DLL MIDLIN40.DLL MIRDB.DLL

MIRDBRES.DLL mirdbspatial.dll ALLTYPE.DLL

PROGRAM.DLL ProgramRes.dll RASTER.DLL

RasterRes.dll REGSVR32.EXE RegTypLib.exe

STYLES.DLL TextFileReader.dll TextFileReaderRes.dll

Thematics.dll TOKENS.DLL UTILITY.DLL

MapInfo MapX Developer Guide v4.5 217

Page 4: DistribMapX

Chapter 16: Distributing Your MapX Application

UtilityRes.dll FIND.DLL FINDRES.DLL

GeoDictionaryManager40.exe

GeoDictionaryManagerIntl40.dll MIGEOREG.DLL

Mapinfow.fnt Mxintl40.dll Tools.dll

ThematicsRes.dll RegisterDS4.exe GEORES.DLL

ALASKA.LAS ALASKA.LOS CONUS.LAS

CONUS.LOS HAWAII.LAS HAWAII.LOS

PRVI.LAS PRVI.LOS STGEORGE.LAS

STGEORGE.LOS STLRNC.LAS STLRNC.LOS

STPAUL.LAS STPAUL.LOS MAPX40.OCX

CUSTSYMB\ CUSTSYMB\YIEL2-32.BMP CUSTSYMB\BADG1-32.BMP

CUSTSYMB\BADG2-32.BMP

CUSTSYMB\BANK1-32.BMP CUSTSYMB\BANK2-32.BMP

CUSTSYMB\BOOK1-32.BMP

CUSTSYMB\CAMP1-32.BMP CUSTSYMB\CAR1-32.BMP

CUSTSYMB\CAUT1-32.BMP

CUSTSYMB\CHUR1-32.BMP CUSTSYMB\COMP1-32.BMP

CUSTSYMB\FARM1-32.BMP

CUSTSYMB\FAST1-32.BMP CUSTSYMB\FIRE1-32.BMP

CUSTSYMB\GLOB1-32.BMP

CUSTSYMB\GOLF1-32.BMP CUSTSYMB\HOSP1-32.BMP

CUSTSYMB\HOUS1-32.BMP

CUSTSYMB\HOUS2-32.BMP CUSTSYMB\HOUS3-32.BMP

CUSTSYMB\HYDR1-32.BMP

CUSTSYMB\INTE1-32.BMP CUSTSYMB\LITE1-32.BMP

CUSTSYMB\LITE2-32.BMP

CUSTSYMB\MAIL1-32.BMP CUSTSYMB\MBOX1-32.BMP

CUSTSYMB\MBOX2-32.BMP

CUSTSYMB\MOSQ1-32.BMP CUSTSYMB\ONEW1-32.BMP

CUSTSYMB\ONEW2-32.BMP

CUSTSYMB\PENC1-32.BMP CUSTSYMB\PIN1-32.BMP

CUSTSYMB\PIN2-32.BMP CUSTSYMB\PIN3-32.BMP CUSTSYMB\PIN4-32.BMP

CUSTSYMB\PIN5-32.BMP CUSTSYMB\PIN6-32.BMP CUSTSYMB\POLI1-32.BMP

218 MapInfo MapX Developer Guide v4.5

Page 5: DistribMapX

MapX Customer Installation

Integrating MapX into Applications at RuntimeWhen you deliver your application to customers, you will need to install:

• The software you created

• MapX Control (Either via the MapX OCX Installer –OR– your own, customized version)

• Related support files

• Maps and geosets that are used by your application

Ideally you will incorporate the installation of MapX into your installation procedure, so

that your end user won’t need to perform a separate installation to install MapX.

There are four main steps to installing and distributing MapX applications:

1. Install the necessary files onto your user's computer.

2. Run utilities (such as regsvr32.exe) to register specific files on the user's system.

3. Add specific keys to the Windows registry

4. Pass in the MapX license string at application runtime.

Note: If you are using MapX in a dialog with Visual C++, VisualBasic, Delphi, or PowerBuilder they will take care of creating MapX with the correct license string and therefore you can skip this section. If you are creating the MapX control using the CMapX::Create() method in Visual C++ you do need to take this extra step.

The files that are installed with MapX can be divided into the following categories:

Required files:

• MapX OCX and its dependent DLLs

• Windows system files: including fonts, MFC, and OLE dlls

CUSTSYMB\RAIL1-32.BMP

CUSTSYMB\RAIL2-32.BMP CUSTSYMB\RAIL3-32.BMP

CUSTSYMB\REST1-32.BMP

CUSTSYMB\STAT1-32.BMP CUSTSYMB\STOP1-32.BMP

CUSTSYMB\SYNA1-32.BMP

CUSTSYMB\TARG1-32.BMP CUSTSYMB\TAXI1-32.BMP

CUSTSYMB\TEMP1-32.BMP

CUSTSYMB\TOWE1-32.BMP CUSTSYMB\TOWE2-32.BMP

CUSTSYMB\TRAF1-32.BMP

CUSTSYMB\TRUC1-32.BMP CUSTSYMB\TRUC2-32.BMP

CUSTSYMB\YIEL1-32.BMP

CUSTSYMB\AMBU1-32.BMP

MapInfo MapX Developer Guide v4.5 219

Page 6: DistribMapX

Chapter 16: Distributing Your MapX Application

Optional files:

• Dataset drivers (used for databinding)

• Import/Export raster handlers

• Maps and Geosets

The Installshield sample provided on the MapX Installation CD only illustrates how to

install the required files. This chapter will cover installation requirements for the required

files and the optional files.

Installing the MapX OCXIf you have installed MapX on your own computer, it’s easy to get a rough idea of how

many files are used by MapX. In previous versions of MapX, all of the files were installed

under the old MapX program directory (which defaults to \Program Files\MapInfo\MapX

4.0\Program). MapX v4.0 and later installs the program files under the following path

“\Program Files\Common Files\MapInfo Sharred\MapX Common”. This directory

should be used for the MapX required files, whereas all of the files necessary for your

application should go under a directory meaningful to the end-user and your specific

application.

Note: MapX uses some files that are not located in the MapX program directory. For example, MapX uses MFC and OLE dlls that reside in the Windows System directory.

We also recommend that the MapX common directory should be: \Program Files\Common

Files\MapInfo Sharred\MapXCommon.

The following table describes what files need to be installed and where they should be

installed to.

FilesWhere to Install Files Other Special

Requirements

Mfc42.dll, msvcp60.dll, msvcrt.dll \Windows\System Do a version check before replacing these files. If older version, during replace files may be in use and require a reboot if that is the case.

220 MapInfo MapX Developer Guide v4.5

Page 7: DistribMapX

Installing the MapX OCX

Olepro32.dll, oleaut32.dll \Windows\System Must be registered using regsvr32.exe

Mapx40.ocx MapX common directory

Must be registered using regsvr32.exe. Prior to registering the OCX, make sure the MapX dependent files are installed.

MMapXColumnInfo.dll MapX common directory

Must be registered using regsvr32.exe

mdatasetint.tlb MapX common directory

Must be registered using regtyplib.exe

FilesWhere to Install Files Other Special

Requirements

MapInfo MapX Developer Guide v4.5 221

Page 8: DistribMapX

Chapter 16: Distributing Your MapX Application

MapX dependent files:ALLTYPE.DLL, AllTypeRes.dll, ColLookupSystem.dll, CommandProcessor.dll, CommandProcessorRes.dll, COMPILER.DLL, COORDSYS.DLL, CoordSysRes.dll, CustomProperties.dll, DAENGINE.DLL, DAEngineRes.dll, DBINFO.DLL, DBInfoRes.dll, DBLAYER.DLL, DBLayerRes.dll, ExprPacket.dll, ExprPacketCreator.dll, ExprPacketCreatorRes.dll, ExprPacketRes.dll, FcnInfoServer.dll, FcnInfoServerres.dll, FIND.DLL, FINDRES.DLL, GEO.DLL, GeoDictionaryManager40.exe, GeoDictionaryManagerIntl40.dll, GeoObject.dll, GeoObjectRes.dll, GEOSET.DLL, GeosetManager40.exe, GeosetManagerIntl40.dll, GeosetRes.dll, LEGEND.DLL, LegendRes.dll, LEXER.DLL, LEXERRES.DLL, MapBasicInternalFcn.dll, MapBasicInternalFcnres.dll, Mapinfow.fnt, MAPINFOW.PRJ, MAPPER.DLL, MapperRes.dll, MAPX.ABB, MAPX.PEN, METADATA.DLL, MIDLG40.DLL, MIDLIN40.DLL, MIRDBRES.DLL, Mxintl40.dll, PROGRAM.DLL, ProgramRes.dll, RASTER.DLL, RasterRes.dll, REGSVR32.EXE, RegTypLib.exe, STYLES.DLL, TextFileReader.dll, TextFileReaderRes.dll, Thematics.dll, TOKENS.DLL, Tools.dll, UTILITY.DLL, UtilityRes.dll, ThematicsRes.dll, GeoRes.dll

MapX common directory

FilesWhere to Install Files Other Special

Requirements

222 MapInfo MapX Developer Guide v4.5

Page 9: DistribMapX

Installing the MapX OCX

MapX font files;ARIAL.TTF, MAPIS___.TTF, MAPSYM.TTF, TTMIAR__.TTF, TTMICG__.TTF, TTMIMI__.TTF, TTMIOG__.TTF, TTMIOS__.TTF, TTMIRE__.TTF, TTMITC__.TTF, TTMIWE__.TTF

Windows\Fonts directory

These fonts have to be installed and registered with the operating system. Please see below for moreinformation.

Nadcon support files:ALASKA.LAS, ALASKA.LOS, CONUS.LAS, CONUS.LOS, HAWAII.LAS, HAWAII.LOS, PRVI.LAS, PRVI.LOS, STGEORGE.LAS, STGEORGE.LOS, STLRNC.LAS, STLRNC.LOS, STPAUL.LAS, STPAUL.LOS

MapX common directory

Only required if using layers with the NAD 27 and NAD 83 coordinate systems.

FilesWhere to Install Files Other Special

Requirements

MapInfo MapX Developer Guide v4.5 223

Page 10: DistribMapX

Chapter 16: Distributing Your MapX Application

The sample Installshield program installs the above files. The sample can be found on the

MapX SDK CD.

MapX also uses some TrueType fonts. These font files (*.ttf) must be copied to Window’s

Font Folder.

Fonts must also be registered with Windows. If you are using a third-party software

package to create your installer, that package might handle font registration for you.

Otherwise, you can register fonts manually, by calling the Win32 AddFontResource routine.

Once a font is properly registered, the registry contains a corresponding key under:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Fonts

Bitmap symbols:TOWE1-32.BMP, POLI1-32.BMP, MBOX2-32.BMP, GOLF1-32.BMP, TOWE2-32.BMP, RAIL1-32.BMP, MOSQ1-32.BMP, HOSP1-32.BMP, IEL2-32.BMP, RAIL2-32.BMP, ONEW1-32.BMP, HOUS1-32.BMP, ADG1-32.BMP, ONEW2-32.BMP, HOUS2-32.BMP, ADG2-32.BMP, HOUS3-32.BMP, ANK1-32.BMP, ANK2-32.BMP, OOK1-32.BMP, AMP1-32.BMP, TRAF1-32.BMP, AR1-32.BMP, TRUC1-32.BMP, RAIL3-32.BMP, AUT1-32.BMP, TRUC2-32.BMP, REST1-32.BMP, PENC1-32.BMP, HUR1-32.BMP, YIEL1-32.BMP, STAT1-32.BMP, PIN1-32.BMP, HYDR1-32.BMP, AMBU1-32.BMP, STOP1-32.BMP,PIN2-32.BMP, INTE1-32.BMP, COMP1-32.BMP, SYNA1-32.BMP, PIN3-32.BMP, LITE1-32.BMP, FARM1-32.BMP, TARG1-32.BMP, PIN4-32.BMP, LITE2-32.BMP, FAST1-32.BMP, TAXI1-32.BMP, PIN5-32.BMP, MAIL1-32.BMP, FIRE1-32.BMP, TEMP1-32.BMP, PIN6-32.BMP, MBOX1-32.BMP, GLOB1-32.BMP,

Underneath the MapX common directory, in a directory called Custsymb. For example: \Program Files\Common Files\MapInfo Shared\MapX Common\Custsymb

Only required if using custom bitmap symbols.

FilesWhere to Install Files Other Special

Requirements

224 MapInfo MapX Developer Guide v4.5

Page 11: DistribMapX

Installing Support for Spatial Server Access

or

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Fonts

Installing Support for Spatial Server AccessIf accessing data in a spatially enabled RDBMS like SpatialWare for Oracle, Informix, or DB2

or Oracle 8i Spatial, then the drivers below are needed.

Registering Files and Installing Dataset DriversAs mentioned in the preceding table, some files need to be ‘registered’. Most of the files that

need to be registered can be registered by running the utility regsvr32.exe:

• regsvr32 /s <filespec of mapx.ocx>

• regsvr32 /s <filespec of olepro32.dll>

• regsvr32 /s <filespec of oleaut32.dll>

If your application uses the ODBC data driver, you must register MODBCDataset.dll and

MMapXColumnInfo.dll. If your application uses the Notes data driver, you must register

MNotesDataset.dll and MMapXColumnInfo.dll. If your application uses either the ODBC or

the Notes data driver, you must register the type library as follows:

regtyplib <filespec of mdatasetint.tlb>

MapX allows you to bind data to a map layer. Please see, "Putting Your Data on the Map"

for additional information.

Note: All of these dataset drivers should be installed in the same directory as the MapX OCX, which is usually found in the MapX common directory: \Program Files\Common Files\MapInfo Shared\MapX Common

Spatial Server Dataset drivers Installation requirements

SpatialWareMapInfoODBC

Miodbc.dll, mirdb.dll, mirdbspatialres.dll, mirdbspatial.dll

Odbc32.dll must exist in system path

Oracle 8i Spatial Mioci.dll, mirdb.dll, mirdbspatialres.dll

Odbc32.dll must exist in system path

MapInfo MapX Developer Guide v4.5 225

Page 12: DistribMapX

Chapter 16: Distributing Your MapX Application

This table illustrates the various options for data binding and what the installation

requirements are. All of the files below must be registered with ressup32.exe.

Installing Raster Format HandlersMapX also allows the developer to incorporate raster images into their application. A MapX

application may open or write to various raster image types. The appropriate drivers must

be included when distributing your application.

MapX can use one of many different libraries to load a raster image. When a raster image is

loaded by MapX, it will search for these DLLs and ask them if the given file can be read by

that DLL. Once one answers yes, MapX knows which DLL will be doing format handling

for the file. The Format handlers will be named "xxxxxxxx.RHx". The base part of the name

is based on the format. The extension always begins with RH, but can end in any letter (A-

Z). When searching for a format handler, MapX starts with RHA, then RHB, and so forth

until RHZ. This allows MapX to prioritize which handlers are used. For example, SPOT

files need to be checked for before any other formats since they are just raw data that can be

confused with other formats. The SPOT handler's extension is RHD. The Halo format

handlers (the standard built in ones) are named RHV. The Lead Tools are named RHX.

Dataset source type Dataset drivers Installation requirements

Lotus Notes Mnotesdataset.dll Notes dataset driver requires nnotes.dll to be locateable through the system path.

ODBC Modbcdataset.dll Odbc32.dll must exist in system path

Delphi v3 MgenDSetDrvr.dll, DSLIBP.DLL

Delphimm.dll must exist in system path

Delphi v4 MgenDSetDrvr.dll, Dslibp4.dll

Borlndmm.dll must exist in system path

Safe Array MsafeArrayDataset.dll

ADO v2.0 MapXADODS.dll, ATL.dll ADO must be installed.

RDO v2.0 MapXRDODS.dll, ATL.dll RDO must be instaled.

226 MapInfo MapX Developer Guide v4.5

Page 13: DistribMapX

Installing Raster Format Handlers

The LEADTOOLS Win32 Pro provided by ©LEAD Technologies, Inc and HALO Imaging

libraries provided by Media Cybernetics are included with MapX. You may use either of

these to display most raster files in MapX. LeadTools will load the entire raster image into

memory at the time the image is referenced in MapX. This will mean that the image will

take longer to load, but panning and zooming will be faster. HALO will only load what it

needs to display into memory, so it will load the image faster, but panning and zooming will

be slower. By default, HALO will be attempted first. You may change this order by either

not including the HALO libraries when distributing your application, or by renaming the

LeadTools handler from a .rhx to a .rhu or anything else not used before the letter “x”. There

may also be some formats which are not supported by either library and therefore will have

their own separate library.

Note: All of these raster handlers should be installed in the same directory as the MapX OCX, which is usually found in the MapX common directory: \Program Files\Common Files\MapInfo Shared\MapX Common.

Here is a list of handlers included with MapX:

Format Handler Required filesSupported raster types and DLL’s needed

All raster types Migeoreg.dll, MIRASTER.DLL

Lead Tools LTFIL70N.DLL, LTKRN70N.DLL, leadtool.rhx

JPG-LFCMP70N.DLL, GIF-LFGIF70N.DLL, TIF-LFTIF70N.DLL,LFFAX70N.DLL PNG- LFPNG70N.DLL, PSD- LFPSD70N.DLL,WMF-LFWMF70N.DLL,BMP-LFBMP70N.DLL

Halo Libraries Halo.rhv, mihiffl.dll BMP-miffbmp.dll,GIF-miffgif.dll, JPG-miffjpeg.dll, PCX-miffpcx.dll,TARGA-mifftga.dll,TIF-mifftiff.dll

TIF TIFF.RHL Or you may use the TIF library provided by Lead Tools or Halo.

SPOT Spot.rhd

MRSID Mrsid.rhe SID-MRSID32.DLL

MapInfo MapX Developer Guide v4.5 227

Page 14: DistribMapX

Chapter 16: Distributing Your MapX Application

Installing Maps and GeosetsRegistering a geoset is a convenient way of registering each MapInfo table associated with

that geoset into the GeoDictionary. By registering a MapInfo table in the GeoDictionary, that

table can be used for autobinding. To get more information regarding autobinding, please

see "Putting Your Data on the Map".

If it is determined that you need to use the GeoDictionary, when you register a geoset,

GeoDictionaryManager40.exe adds appropriate entries into the Geodictionary (geodict.dct).

If the Geodictionary does not exist, GeoDictionaryManager40.exe creates one.

This step must be done after all of the Geosets and associated tables are installed on the

user’s machine. Double check your geoset to see what the expected paths are for each table.

For example, if you created a geoset using MapInfo tables on different areas of your hard

drive, the geoset will specify the full path to anything not in the same directory as the

geoset. If redistributing this geoset, the tables will have to be found in the same paths as the

original geoset. To avoid this problem, copy all MapInfo tables into the same directory prior

to creating the geoset. Then create the geoset in that same directory.

Adding Keys to the Windows RegistryMapX also uses the following three registry keys (which your installer must create on the

end-user's system, if they do not exist already). The MapX installer creates these three keys

All Grid types MIGRID.DLL, MIRASTER.DLL

MapInfo GRID and Hillshading

MIG.GHL MIG-GRIDDLL.DLL

Format Handler Required filesSupported raster types and DLL’s needed

228 MapInfo MapX Developer Guide v4.5

Page 15: DistribMapX

Passing in the MapX License String

when you install MapX on your system. Therefore, if you want to see what these registry

keys should look like, view your system's registry using a utility such as regedit.exe.

Note: The GeoDictionary path is used when adding a geoset to the MapX object without specifying the full path of the Geoset and when using autobinding. In addition, the SearchPaths key is not necessary if not using the GeoDictionary. See “Installing Maps and Geosets” to determine whether or not these keys are necessary for your application.

Passing in the MapX License StringIn order to instantiate a runtime version of MapX on your user ’s computer, the license string

must be passed in at the time of object creation during the executing of your application.

Note: If you are using MapX in a dialog with Visual C++, VisualBasic, Delphi, or PowerBuilder they will take care of creating MapX with the correct license string and therefore you can skip this section. If you are creating the MapX control using the CMapX::Create() method in Visual C++ you do need to take this extra step.

Visual C++Again, if using MapX in a dialog in Visual C++, you do not need to perform this step.

Key Description

HKEY_LOCAL_MACHINE\Software\_MapInfo\MapX 4.0\GeoDictionary

String - The GeoDictionary key has the file specification for the geodictionary file. Example: C:\Program Files\myappdir\Maps\GeoDict.DCT

HKEY_LOCAL_MACHINE\Software\_MapInfo\MapX 4.0 \SearchPaths

String - The SearchPaths key has semicolon-delimited file specifications of where map files and geosets may exist; it defaults to an empty string ("") other than in the directory specified in the GeoDictionary key.

HKEY_LOCAL_MACHINE\Software\_MapInfo\MapX 4.0\ CommonDLLDir

String - Has the location of the folder where the OCX and support files are Located. Example: \Program Files\Common Files\MapInfo Shared\MapX Common

MapInfo MapX Developer Guide v4.5 229

Page 16: DistribMapX

Chapter 16: Distributing Your MapX Application

In order to successfully create the MapX object, you must pass the license string as the

bstrLicKey parameter to CMapx::Create().

Redistributing Your MapX Application with MrSIDIn the event Licensee wishes to deploy an application which supports the MrSID file format

(*.sid), Licensee shall include the following text:

MrSID software (specifically the mrsid32.dll) is used under license and is Copyright © 1995-99, LizardTech, Inc., 1008 Western Ave., Suite 200, Seattle, WA 98104. All rights reserved. MrSID is protected by U.S. Patent No. 5,710,835. Foreign patents are pending. Unauthorized use or duplication prohibited.

Patented technology in the Software was developed in part through a project at the Los Alamos National Laboratory, funded by the U.S. Government and managed by the University of California. The U.S. Government has reserved rights in the technology, including a non-exclusive, nontransferable, irrevocable, paid-up license to practice or have practiced throughout the world, for or on behalf of the United States, inventions covered by the patent, and has other rights under 35 U.S.C. § 200-212 and applicable implementing regulations. For further information, contact Lizardtech.

230 MapInfo MapX Developer Guide v4.5