MapPoint Forums

MapForums

Community of VE/MapPoint 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

Register Blogs FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #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


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 11:06 AM.


Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0
MP2K Magazine
Visitor Map

MyTravel Flights
Book MyTravel Holidays At Holiday Hypermarket. MyTravel arranges flights and accommodation for great value to great destinations.

Portugal Weather
Check Portugal Weather before you travel. We provide information on Portugal including weather, flights and accommodation.

Turkey Holiday
Any Turkey Holiday should include a visit to Anadolu; the Anatolian high central plateau is where Turkish culture is rooted. Book a cheap Turkey Holiday online at dealchecker.co.uk.

Holidays to Dominican Republic
Holidays to Dominican Republic offer a wealth of natural beauty and magnificent views. Come alive in the splendor of the Dominican Republic!

Cheap Balearics Holidays
Cheap Balearics holidays are available if you know when to book and who to book with. The Balearics have many fascinating places to visit all year round. The partying never stops.

Holiday Packages
Spoil yourself and your loved ones with one of the great Holiday Packages from Travel.co.uk.

Holidays in Cyprus
Visit the tombs of the island kings! Visit On The Beach for information on holidays in Cyprus.


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