MapPoint Forums

MapForums

Community of MapPoint and Virtual Earth Users and Developers




array of locations

This is a discussion on array of locations within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; Is there a way to make a dynamic array ? All samples I found until now use following syntax. The ...


Go Back   MapPoint Forums > Map Forums > MapPoint 2006/2009 Discussion

Today's Posts Twitter Feed Register Blogs FAQ Members List Calendar Search Today's Posts Mark Forums Read



Click here to register

Reply

 

LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 04-11-2003
Junior Member
White Belt
 
Join Date: Apr 2003
Posts: 4
array of locations

Is there a way to make a dynamic array ?
All samples I found until now use following syntax. The don't allow to change the upper limit of the array, or to use a variable instead.
Dim objLocs(1 To 5) As MapPoint.Location
When i try to use the standard VB way to create a dynamic array :
Dim objLocs() As MapPoint.Location
PPCount = 10
Redim objlocs(PPcount[/i])
I always get an error on the line where the polygon is added.
mymap.shapes.addpolygon objlocs
My problem is that I want to draw different polygons on my map , depending on data in an access database.
Sorry about my bad english, I hope someone understands my problem and is able to give me some advice.

Thanks a lot
[/i]
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #2 (permalink)  
Old 04-11-2003
Junior Member
White Belt
 
Join Date: Apr 2003
Posts: 4
Array of locations

Correction of previous topic
Is there a way to make a dynamic array ?
All samples I found until now use following syntax. They don't allow to change the upper limit of the array, or to use a variable instead.
Code:
Dim objLocs(1 To 5) As MapPoint.Location
When i try to use the standard VB way to create a dynamic array :
Code:
Dim objLocs() As MapPoint.Location, PPCount as integer 
PPCount = 10 
Redim objlocs(PPcount)
I always get an error on the line where the polyline is added.
Code:
mymap.shapes.addpolyline objlocs
My problem is that I want to draw different polylines on my map , depending on data in an access database.
Sorry about my bad english, I hope someone understands my problem and is able to give me some advice.

Thanks a lot
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #3 (permalink)  
Old 04-14-2003
Senior Member
Black Belt
 
Join Date: Jul 2002
Posts: 5,138
array of locations

You can do the following:

Redim objlocs(1 to PPcount[/i]-1)

That might work. Or try:

Option Base 1

somewhere in the code.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #4 (permalink)  
Old 04-14-2003
Junior Member
White Belt
 
Join Date: Apr 2003
Posts: 4
array of locations

Thanks for your reply. It works.
Indeed arrays in mappoint cannot be zero based for some obscure reason
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Reply

Tags
array, locations


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads

Thread Thread Starter Forum Replies Last Post
SetFieldsVisibleInBalloon - how do I set up the array jtowell MapPoint 2006/2009 Discussion 7 05-16-2005 12:59 PM
How to access to an array of pushpins that were added ? Jaba MapPoint 2006/2009 Discussion 4 01-13-2005 06:20 AM
Help! Import Custom Symbol Array Anonymous MapPoint 2006/2009 Discussion 2 01-07-2005 03:29 PM
Addpolyline , Array , Visual Basic and Other languages Anonymous MapPoint 2006/2009 Discussion 2 08-26-2004 03:58 AM
Importing address with an array of fields specified jscott099 MapPoint 2006/2009 Discussion 1 12-30-2003 10:10 PM


All times are GMT -5. The time now is 04:19 AM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0 RC2
MP2K Magazine
Visitor Map

Antalya Holiday
Check out the Antalya holiday options through UlookUbook and find amazing offers that suit your pocket...



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59