# Array, how to draw a line dynamically... and a map

**URL:** <https://forum.kirupa.com/t/array-how-to-draw-a-line-dynamically-and-a-map/262889>\
**Category:** Uncategorized\
**Created:** [June 10, 2008, 8:44pm UTC](https://forum.kirupa.com/t/array-how-to-draw-a-line-dynamically-and-a-map/262889 "2008-06-10T20:44:30Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Leo75](https://avatars.discourse-cdn.com/v4/letter/l/779978/32.png) [@Leo75](https://forum.kirupa.com/u/Leo75)\
**Post date:** [June 10, 2008, 8:44pm UTC](https://forum.kirupa.com/t/array-how-to-draw-a-line-dynamically-and-a-map/262889/1 "2008-06-10T20:44:30Z")

</div>

Hi there.  
I am doing a small map of my city -a very small city-. And thinking to do the common feature where the user clicks a starting point and an ending point and route will be displayed on the map.

So far, i know that i need to create a 2D array.

But here are some questions that i have:  
How would i draw, dinamically, the lines (the route, or path to be taken)?  
And how to handle (in case i really need a 2D array) a huge array? (since it always shows me a window msg telling that this script is taking long… bla bla bla)…  
Thanks.  
Cheers.  
Leo.
