MapInfo Pro Developers User Group

 View Only
  • 1.  Is MapBasic still being developed or will it be replaced?

    Posted 11-23-2017 22:01

    Hi all,

    Recently I've been working with a lot of programming languages which are undergoing continual development (e.g. Ruby, JavaScript, C#.NET,...). This actually makes programming in these languages, not only easier, but more fun also.

    Recently I had to go back and fix some old MapBasic code I made about a year ago (just a minor fix which turned into a major improvement to the code maintainability). During this time it hit me how little MapBasic feels like it's changed over the recent years.

    I've also been thinking over the past year about reinventing MapBasic in JavaScript (using COM, Microsoft.NET, CLR and Exo.AHK) and open sourcing the code. Before I was building my own MapBasic compiler (Extended MapBasic) but that project halted due to my own lack of foresight (I'd need to re-write the entire code, something I don't have time for at the moment...)

    Anyway, back to the question at hand, is MapBasic still being actively developed at PitneyBowes? Or is PB focussing more on the .NET APIs? If so is the intention to eventually replace MapBasic with a more modern language?



  • 2.  RE: Is MapBasic still being developed or will it be replaced?

    Employee
    Posted 11-26-2017 17:29

    ?Hi Pick,

     

    Great question.

    As a Software Architect on the Pro team responsible for Extensibility I can answer your question.

    We have been extending our .net capabilities on Pro for a few years now. We plan to continue this. For example in 17.0 we added a new Table Object model for via .net that expose an up to date list of tables and table properties that is easy to use from .net. In addition all UI customization is easy to do via .net languages, including creating your own windows integrated into the docking manager. Also in 17.0 we are introducing a new .efficient net object model for reading/writing/searching/updating MapInfo tables (including geometry) from .net. This is thread safe and can be used on background threads if needed.

     

    That being said we are not abandoning mapbasic.  We continue to expose new functionality via mapbasic and improve the language. As the Pro UI uses mapbasic internally that is not going to change. Much of pro functionality is still only available via mapbasic. .NET based addins still need to use mapbasic to create maps, layouts etc. We have extended mapbasic to better support .NET integration. New layout smart text uses mapbasic expressions at its heart.

     

    Our new Raster capabilities are all written as a .NET addin using mapbasic where needed. Many of our sample applications are written in .NET but call out to the mapbasic compiler for the needed mapbasic parts (every addin still requires at least a small mbx).

     

    We have not updated the mapbasic IDE, it is true although we have thought about it.

    In summary we are expanding .net support as we move forward but will continue to support and expand mapbasic as well.

     

    Please feel free to reply with comments.

     

    -Bob



  • 3.  RE: Is MapBasic still being developed or will it be replaced?

    Posted 11-26-2017 20:10

    Hi Bob, thanks for replying (and on a weekend of all things!).

    In general it's good to hear that MapBasic isn't being dropped, though i do find the lacking of certain features (e.g. classes, structs, pointers) frustrating at times.

    I have actually found it quite unfortunate on several occasions that .NET addins require an MBX to launch 😋. In the past I was hoping I'd be able to use COM interop to launch a .NET add-in, but found that was unfortunately not possible without an MBX. Perhaps a future feature? 😋 To get around this, for my Javascript based system, I've been testing compiling C# to DLLs dynamically with DLR. This way I can make sure a fixed MBX can call the same DLL, but each time with different code.

     

    I did start building an open source IDE for MapInfo. I seem to remember the last time i worked on it I chickened out as I realised I'd have to setup a system to download a MapBasic compiler, because I doubted I could transfer the compiler with the IDE (for legal reasons), and although I started building a MapBasic compiler, I never did finish it. That being said there are so many features I'd like to add to the IDE (e.g. ribbon editors, ability to attach binary data to files, automatically building project files, generation of header files from code etc.).

     

    It does already have syntax highlighting. It is being built with Ace (ace.c9.io) using Electron (https://github.com/electron). You can find the started highlighter here: https://github.com/sancarn/Ace-MapBasic-Syntax. Perhaps at some point PB could open an open source IDE, it'd at least prevent the legal distribution issues and would speed up development (depending on how many others would be willing to chip in). Anyway, I'll stop rambling!



  • 4.  RE: Is MapBasic still being developed or will it be replaced?

    Employee
    Posted 11-27-2017 10:58

    ?We have considered some of your ideas such as allowing .net addins without an mbx, creating a new IDE as well as providing a .net version of the mb compiler which would allow making an open source IDE easy.

    Unfortunately right now we are not pursuing any of them :-(



  • 5.  RE: Is MapBasic still being developed or will it be replaced?

    Posted 11-27-2017 12:03

    Never mind, of course it doesn't stop us working on an OS IDE, just limits the ease of distribution. Thanks for all the detailed responses though :)