Load MapInfo *.tab file

Apr 25, 2012 at 6:58 AM
Edited Apr 25, 2012 at 8:38 AM


I'm new to dotSpatial and have created a test application trying different things.

Everything is going great(loading shape files, creating points, etc etc..), but I encountered a problem when I wanted to load a *.tab file.

I've loaded GDAL using the aproach of appManager + Plugins folder (http://mudnug.wordpress.com/2011/11/23/how-to-support-loading-extensions-in-dotspatial/) nevertheless i cant seem to be able to load *.tab files. What am I missing ?

I get the following:

"The specified file type is not supported."



Apr 25, 2012 at 5:25 PM

You probably have extensions working OK, but the GDAL provider doesn't use GDAL to its full potential.


As far as rasters are concerned, only the following are opened (a few vector formats are opened as well):

case ".asc":
    return "AAIGrid";
case ".adf":
    return "AAIGrid";
case ".tiff":
case ".tif":
    return "GTiff";
case ".img":
    return "HFA";
case ".gff":
    return "GFF";
case ".dt0":
case ".dt1":
case ".dt2":
    return "DTED";
case ".ter":
    return "Terragen";
case ".nc":
    return "netCDF";

Apr 26, 2012 at 2:01 PM

Hi mudnug,

Thank you for the reply, unfortunately it generates a new question :D

How is the GDAL provider enabled to use GDAL to its full potential ? Am i missing dlls ?

Apr 26, 2012 at 6:24 PM

There has been some (tedious) work done to delete a lot of duplicate code in this extension; so things are looking better. Unfortunately, it still requires you add the extension ".tab" in several places such as the switch case statement above (assuming it is a raster type)  and any of the other file extensions you want to support. You can search for one of existing extensions (like tif) to see where the code needs to be modified.