|
Nearcode |
|
Example Name: NcBatch Language: C API type: Client/Server API component filename: mcclient.dll
Environment: Windows 2000, XP, |
|
What does it do? |
|
Demonstrates the use of Nearcode client API. The program
demonstrates simple batch functionality taking an input file of postcodes,
partial postcodes or towns and performing a nearestrecords
lookup. The results are output to stdout.
|
|
Could be used as a
starting point for: |
|
Writing a Nearcode batch application. |
|
Where to find the
example code: |
|
After running the setup from the Nearcode CD to install the
client APIs you will find these examples installed (by default) in: C:\Program Files\Capscan\SDK\Nearcode Client
API\DLL\Examples\c\NcBatch If you have installed to another location you will need to
change the path where necessary.
|
|
What each file does: |
|
File name What does it do? ncbatch.c The C
example code. Readme.txt Command line
options for binary executable example.dat Example batch
input file. NcBatch.dsp Microsoft
Visual Studio C++ 6.0 project file. |
|
Preparing to run the
example: |
|
Please make sure that you have installed the Nearcode Server and that it is up and running. If you install the Libraries example data during installation a LibrariesExample pool will have been created. Else you will need to configure a Nearcode server to run a Nearcode pool.
|
|
Running the example: |
|
1.
Make sure that the API library is in the
search path. 2.
Open the NcBatch.dsp project file using
Visual Studio 6. 3.
Select Rebuild All from the Build menu to
build the example. 4.
From a command prompt run ncbatch.exe with
the following parameters: -p<pool name> filename EG: ncbatch –p LibrariesExample example.dat |
|
Trouble-shooting and
hints: |
|
1.
If you are running on a LAN make sure that
the Capscan Pool Manager is running correctly. To do this you can use the PoolMan Admin application that is installed along with
the Capscan Pool Manager. 2.
If you are using a firewall make sure that
it is not blocking this example or the Capscan Pool Manager. By default the Capscan Client/Server uses
port 27920 for sending and receiving data. 3.
For more hints and tips please see the SDK
bookshelf documentation.
|