I have been looking for a straight forward way to create a TabFeatureLayer. Till now the best option I have found is:
TabFeatureLayer.CreateTabFile(fileName, path, New List(Of Feature))
Where the "new List(of Feature)" is an empty list. However, if after this call I issue a:
TabFeatureLayer.BuildIndexFile(<fileName>); I am getting an exception regarding "Not supported TAB text format" (or something like this). I assume that since the List<feature> is empty the Tab factory "assumes" that this is a featureless layer(!). Of course this is not the case and I am questioning as to what is the best way to start a new Tab layer when you have no features at hand. Something like the equivalent of: ShapeFileFeatureLayer.CreateShapeFile(ShapeFileType.Polygon, <fileName>, <ShpDataBaseColumns>); would have been more appropriate. And a final point, in one of the previous chats we had established that when dealing with ShapeFiles, if you want to get One feature based on its Column value, you should go through the GeoDbf class to access the DBF file etc etc etc, otherwise the default FeatureSource method is loading the layer into the memory with disastrous results if the file is big. What is the equivalent for Tab files? Or does the GetFeaturesByColumnValue works correctly in this implementation? Kind Regards Yiannis </feature>
1. Creating tab layers does seem to require an empty list of Features that causes issues with indexes 2. Tab layers seems to be created without any projection information and there is no way to set it. As a result opening tab files from other software is not a success story always. 3. Tab layers seems to load in the memory when searching by column value. Any work around like the one for Shp layers? 4. Textual Tab layers are not supported (seems to be the root of issue 1)
Any help will be really appreciated. Kind Regards Yiannis
1. It has been fixed in TabFeatureSource. Please get the latest version 5.5.133.0 or higher from helpdesk.thinkgeo.com with your own account. 2. Thanks for your suggestion, we are focus on the development of it, please keep an eye on the thread. 3. It has been fixed now, please get fix from the latest version 4. We are still doing the investigation, but seems like it’s complicated for us to support it now, anyway, we will keep on it and any progress will let you know.
Hi Ioannis, Please check the answer of the question: Tab layers seems to be created without any projection information and there is no way to set it. As a result opening tab files from other software is not a success story always We have added two methods “GetCurrentProjection” and “SetCurrentProjection” to “TabFeatureSource”, and add a new class TABProjInfo which represents the projection used in .tab file. Here is some code about how to use it: GetCurrentProjection: TABProjInfo proj = tabFeatureLayer.FeatureSource.GetCurrentProjection(); SetCurrentProjection: TABProjInfo proj = new TABProjInfo([parameters]);
Int projID = 23, ellipseSoidID=77, unitsID= 1, projParams = null;
tabFeatureLayer.FeatureSource.SetCurrentProjection(proj, projID, ellipseSoidID, unitsID, projParams); Please have a try and any questions please let us know. Now we are still working on the 4th item, it’s a bit complicated and maybe we need about 3 more days for it.
Just remind you that please make sure get the latest version 5.5.136.0 or higher from helpdesk.thinkgeo.com with your own account, and then have a try.
Hi Ioannis, We have got a way to support the Textual .tab file, but before integrating into our products, can you send us a sample data for test? We just would like to make sure the way is correct. Looking forward to your sample data.
Thank you for the replay. I was on holidays thus I couldn't answer quick enough. My test data are around 35Mb and I wouldn't like to chop them as this may introduce incompatibility issues. Is there any way I can send you a zip file as the forum does not allow such a big file to be uploaded?
The data are on their way via "yousendit.com" as our server couldn't not allow such a big file to be emailed. Please check your spams in case you miss it.
Sorry for waiting, we are preparing the 6.0 release, so it’s really busy these time.
Thanks for your data, but it’s expired when I try to download it today, could you please re-active it and I will begin working on this as soon as I got the data.
Sorry for waiting, there is something wrong with the data, we try it with GlobleMapper, MapInfo Explorer, TatukGIS Explorer etc. but all are unable to open that data. Could you please check it?
Hello and thank you, the files here seem to open fine on MapInfo 8.5 and QuantumGIS.... Can you provide me links with the software you used to download an evaluation version?
EDIT: GLOBAL MAPPER does not open but that migth well mean that it is expecting some shape features
The version of MapInfo we are using is 10.5, it works fine with the tab file we downloaded, but runs into error with your data, please check the attached image.
Also we tried it with QuantumGIS 1.7.4, it always shows blank, I think it should runs into error as well.
Is it possible to give a video to us about how you load these files? Sorry to say if it is unable to loaded with All these Explorers we have mentioned we will not work on it, you need contact your account rep to ask a professional service.
I think there is a misunderstanding. The file I send you is a textual tab file as Johny requested. As such of course you will get BLANK in Qunatum Gis since it has no features to present but you will see the textual data if you right click after you load it and click on Atribute table. Some with MapInfo. It opens it but of course only the attributes are visible as a table. So there is no error there. Are you sure that we are talking about the same issue here?
Sorry for waiting, we made some more test on this issue, and we found that we can get the feature type, and the feature native type is TABFCNoGeomFeature, so the feature isn’t handled in our tab system.
We will investigate how to support it, I thought that it might take a few days to do, I can tell you a result by comparing our codes with native C in tomorrow later.
Thanks for your patience, we did a research and found that we do not support the texture tab file, because the only way we read tab file is that we read features first, and set the feature.ColumnValues by reading the *.dat file, but you said that his .tab file just contains texture information without any coordinates, it breaks the rules we read the Tab process, I think we are unable to do any enhancements.