MapInfo Pro Developers User Group

Welcome to the MapInfo Pro Developers community!  We are a group dedicated to the discussion and understanding of MapBasic and .Net MapInfoPro AddIn development. Bring your questions and ideas here. This group includes several members of the Pro development team from around the world.

Please feel free to start a discussion in the discussion tab or join in a conversation.

Product Information  Ideas Portal  MapInfo Community Downloads

Discussions

Members

Resources

Events

 View Only
  • 1.  Hi Everyone. Does anyone have any experience using an mbx called Connect The Dots? It is not generating my polyline in order of the points in the table but in the opposite direction. Regards, Angelene

    Posted 10-16-2017 02:18


  • 2.  RE: Hi Everyone. Does anyone have any experience using an mbx called Connect The Dots? It is not generating my polyline in order of the points in the table but in the opposite direction. Regards, Angelene

    Posted 10-15-2017 22:44

    Hi Angelene,

    Yes I've seen a similar MBX for dot-to-dot line creation. Just to confirm, the resulting line object created for your dataset is spatially correct except for the line creation. Is this correct? A couple of approaches to resolve this (I'm sure there's more); 1. The logic of the MBX could be adjusted, 2. Reverse line direction. What are the implications of having the line in the reversed direction - is this significant for subsequent processes?

    Cheers, Ashley



  • 3.  RE: Hi Everyone. Does anyone have any experience using an mbx called Connect The Dots? It is not generating my polyline in order of the points in the table but in the opposite direction. Regards, Angelene

    Posted 10-15-2017 22:58
    Hi Ashley Yes that is correct. The line is spatially accurate just running in the wrong direction. I’m very new to scripting so I don’t know how to reverse the logic. And as I said I thought that if I had the MapBasic window open I would be able to see the commands being executed but I didn’t see anything? I don’t know why? Yes I could use the reverse line direction however I have about 1400 lines to verify and potentially reverse. That’s why I was excited to find this tool as I thought it would save me a lot of time. Line direction is very important to this project as the lines represent road centrelines. My next step in to run chainages along these lines and then pavement and seal footprints. Angelene Angelene Wright Asset/GIS Officer South Burnett Regional Council PO Box 336 Kingaroy QLD 4610 ' 07 4189 9537 • awright@southburnett.qld.gov.au : www.southburnett.qld.gov.au [Description: Description: sbrcBar] DISCLAIMER: This electronic mail message is intended only for the addressee and may contain confidential information. If you are not the addressee, you are notified that any transmission, distribution or photocopying of this email is strictly prohibited. The confidentiality attached to this email is not waived, lost or destroyed by reasons of a mistaken delivery to you. The information contained in this email transmission may also be subject to Right to Information and Information Privacy legislation.


  • 4.  RE: Hi Everyone. Does anyone have any experience using an mbx called Connect The Dots? It is not generating my polyline in order of the points in the table but in the opposite direction. Regards, Angelene

    Posted 10-15-2017 23:14

    Hi Angelene,

    Thanks for the clarification. Yes having the MapBasic window open would typically mean that commands/functions executed within the MapInfo Pro session would be reflected here, however when running a compiled MapBasic application (MBX) this is an exception to the rule. If you do things like open Tables/Workspaces & create a thematic or execute a SQL you'd definitely see the related functions.

    There are a couple of ways to reverse the lines, probably the quickest would be:

    1. Make the layer with lines editable
    2. Select all objects (lines) using a Select tool
    3. Within the MapCAD toolset (ships with MapInfo Pro), use the following command (taken from v16, might differ slightly on other versions) Spatial>Edit>Modify>Reverse Line Direction option

    All lines are reversed at once, need to Save Table to make this permanent. Using this you can work with the MBX you have for the Connect-the-Dots then quickly finalise the new object direction. Does this workflow suit?

    Thanks, Ashley



  • 5.  RE: Hi Everyone. Does anyone have any experience using an mbx called Connect The Dots? It is not generating my polyline in order of the points in the table but in the opposite direction. Regards, Angelene

    Posted 10-15-2017 23:24
    Fantastic Ashley! Yes that will work just fine. Thank so much! Regards Angelene Angelene Wright Asset/GIS Officer South Burnett Regional Council PO Box 336 Kingaroy QLD 4610 ' 07 4189 9537 • awright@southburnett.qld.gov.au : www.southburnett.qld.gov.au [Description: Description: sbrcBar] DISCLAIMER: This electronic mail message is intended only for the addressee and may contain confidential information. If you are not the addressee, you are notified that any transmission, distribution or photocopying of this email is strictly prohibited. The confidentiality attached to this email is not waived, lost or destroyed by reasons of a mistaken delivery to you. The information contained in this email transmission may also be subject to Right to Information and Information Privacy legislation.


  • 6.  RE: Hi Everyone. Does anyone have any experience using an mbx called Connect The Dots? It is not generating my polyline in order of the points in the table but in the opposite direction. Regards, Angelene

    Posted 10-15-2017 23:28

    You're welcome - another win for the Li360 community!



  • 7.  RE: Hi Everyone. Does anyone have any experience using an mbx called Connect The Dots? It is not generating my polyline in order of the points in the table but in the opposite direction. Regards, Angelene

    Posted 10-16-2017 01:44
    Absolutely! Angelene Wright Asset/GIS Officer South Burnett Regional Council PO Box 336 Kingaroy QLD 4610 ' 07 4189 9537 • awright@southburnett.qld.gov.au : www.southburnett.qld.gov.au [Description: Description: sbrcBar] DISCLAIMER: This electronic mail message is intended only for the addressee and may contain confidential information. If you are not the addressee, you are notified that any transmission, distribution or photocopying of this email is strictly prohibited. The confidentiality attached to this email is not waived, lost or destroyed by reasons of a mistaken delivery to you. The information contained in this email transmission may also be subject to Right to Information and Information Privacy legislation.