+ Reply to Thread
Results 1 to 8 of 8

Calculating Distance between 2 points.

  1. #1
    Registered User
    Join Date
    08-19-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    7

    Calculating Distance between 2 points.

    I'm having trouble calculating multiple distances for different sets of points.
    I can make the code to calculate a single distance between 2 points but I cannot make the program to calculate multiple points with a single click. If anyone can help, that would be great. This is what I have so far to calculate a single distance for 2 points.
    Please Login or Register  to view this content.
    I will attach the file as well as I have more questions in it.

    Thank you.
    Attached Files Attached Files
    Last edited by isdouble; 08-19-2012 at 11:35 PM.

  2. #2
    Forum Expert
    Join Date
    01-15-2007
    Location
    Brisbane, Australia
    MS-Off Ver
    2007
    Posts
    6,591

    Re: Calculating Distance between 2 points.

    Hi

    How about
    Please Login or Register  to view this content.
    Also, can you edit your post and put your code into code tags. Makes things much easier to read.

    rylo

  3. #3
    Registered User
    Join Date
    08-19-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    7

    Re: Calculating Distance between 2 points.

    Sorry about that. Fixed that.
    Thank you so much for the help!
    Is there any other questions that you can answer in the attachment?
    Especially counting the how many points pair up?
    Sorry for asking so much but my book Introduction to VBA For Excel doesn't really cover these materials much.
    Thank you again!

  4. #4
    Forum Expert
    Join Date
    01-15-2007
    Location
    Brisbane, Australia
    MS-Off Ver
    2007
    Posts
    6,591

    Re: Calculating Distance between 2 points.

    Hi

    1) Where is the output to go?
    4) Don't know what you mean.
    5) Don't know what you mean.
    6) what 5 lines, what are they changed to, where is the changed data going.....

    How about some examples.

    rylo

  5. #5
    Registered User
    Join Date
    08-19-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    7

    Re: Calculating Distance between 2 points.

    Sorry about the vague questions. Please forget about 4 5 and 6.
    For #1, it goes to Cells(1,6)
    Sorry again for the confusion.
    Thanks again!

  6. #6
    Forum Expert
    Join Date
    01-15-2007
    Location
    Brisbane, Australia
    MS-Off Ver
    2007
    Posts
    6,591

    Re: Calculating Distance between 2 points.

    Hi

    Try again
    Please Login or Register  to view this content.
    rylo

  7. #7
    Registered User
    Join Date
    08-19-2012
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    7

    Re: Calculating Distance between 2 points.

    Great! Thank you so much rylo! I really really appreciate it.

  8. #8
    Forum Expert Cutter's Avatar
    Join Date
    05-24-2004
    Location
    Ontario,Canada
    MS-Off Ver
    Excel 2010
    Posts
    6,451

    Re: Calculating Distance between 2 points.

    @ isdouble

    Based on your last post it seems that you are satisfied with the solution(s) you've received but you haven't marked your thread as SOLVED. I'll do that for you now but please keep in mind for your future threads that Rule #9 requires you to do that yourself. If your problem has not been solved you can use Thread Tools (located above your first post) and choose "Mark this thread as unsolved".
    Thanks.

    Also, as a new member of the forum, you may not be aware that you can thank those who have helped you by clicking the small star icon located in the lower left corner of the post in which the help was given. By doing so you can add to the reputation(s) of those who helped.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1