MapPoint Forums

MapForums

Community of VE/MapPoint Users and Developers




How to determine territory of a recently placed pushpin ?

This is a discussion on How to determine territory of a recently placed pushpin ? within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; I know how to place pushpins and play with latitude/longitude and everything, but I am so far unable to determine ...


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

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 05-04-2006
Junior Member
White Belt
 
Join Date: Feb 2006
Posts: 10
How to determine territory of a recently placed pushpin ?

I know how to place pushpins and play with latitude/longitude and everything, but I am so far unable to determine the territory name for a pushpin I just placed (using VBA).

I have about 50 territories in the united states and would like to place a pushpin, determine it's territory and delete the pushpin.

Determining the territory is my issue. I tried doing a search but all of those who have posted this question did not get any answer. I hope i'll be more successful !

Thank you for your help it will be greatly appreciated.

Sonicman
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 05-04-2006
Senior Member
Black Belt
 
Join Date: Nov 2004
Posts: 2,122
Hi,

I hope you have more success if it can be done and someone know how. i dont...
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 05-06-2006
Junior Member
White Belt
 
Join Date: Feb 2006
Posts: 10
anyone else ?

Hi Wilfried

thanks for posting

Anyone else have any idea how to do this ? Or is it just not possible with mappoint ?

Alex
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 05-07-2006
Junior Member
White Belt
 
Join Date: Feb 2006
Posts: 10
Could this be adapted to work ?

Here is some code posted by a guest on another topic. Does anyone think it could be adapted to find the territory of a pushpin ?

Quote:
Here is the code to read the linked Territory. I was wondering if some body has dome the same but with Manually created Territory

With objMap.DataSets
szconn = objMap.Path & "C:\MapPoint\pushpin\Terrs.xls!Sheet1!A1:E127"
Set mpDataSet = .ImportTerritories(szconn, , geoCountryUnitedStates, , geoImportExcelA1)
End With

Dim objRecordset As Recordset
Set objRecordset = mpDataSet.QueryAllRecords
Dim strLookUp As String
ReDim Preserve strRegion(0)
x = 0
'Get the values
Dim vals As String
objRecordset.MoveFirst
Dim i As Integer
Do Until objRecordset.EOF
strLookUp = Trim(objRecordset.fields("Territory"))
ReDim Preserve strRegion(x)
strRegion(x) = strLookUp // I have the list here...
x = x + 1
End If
objRecordset.MoveNext

Loop
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #5 (permalink)  
Old 05-12-2006
Junior Member
White Belt
 
Join Date: Feb 2006
Posts: 10
Still no solution after two weeks

After two weeks of searching and posting I still haven't found a solution to this problem. I decided to reply to my own post again to make it sticky.
Maybe someone will find a solution and share it ?

Alex
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #6 (permalink)  
Old 05-22-2006
Member
Green Belt
 
Join Date: Mar 2005
Posts: 96
Hi,

Quote:
After two weeks of searching and posting I still haven't found a solution to this problem. I decided to reply to my own post again to make it sticky.
Maybe someone will find a solution and share it ?
I have an idea but I have to test with your Data. Could u send me your file with sample Data to be sure I understand your problem.



Mohamed@atlascouscous.com
__________________
Mohamed
www.AtlasCouscous.com
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #7 (permalink)  
Old 05-23-2006
Member
Green Belt
 
Join Date: Mar 2005
Posts: 96
Hi,

I don't know what's your progamming language, so I give you the method I used to resolve that:

( By the way, Why do you add a PushinPin and delete it? It's more elegant to use the "BeforeClick" Event )

Never mind, here is the idea :

3 steps:

- When you import your territories, you are obliged to have a GeoFieldType like Postal Code. So, for each Territory Name, you Know the corresponding Postal Codes ( in a file , in an Array, etc. )

- When you add a PushPin , by a Reverse Geocoding function ( you have a lot in this forum ) , you can get the StreetAddress Property and the GeoFieldType value like the Postal Code

- Now you do a search in the file or array where you have your territories and geoFieldTypes to find the correponding Territory Name

Ciao

P.S.
If you add programatically your PushPins, it's easy to save any information you have with the NOTE property. If you put the Territory Name in the NOTE property of a PushPin, you can get that information when you want.
__________________
Mohamed
www.AtlasCouscous.com
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #8 (permalink)  
Old 09-16-2006
Junior Member
Yellow Belt
 
Join Date: Feb 2006
Posts: 12
Send a message via Yahoo to renatoa
I don't know if still useful, but I developed for one of my apps a method to return the clicked territory on map (on before click event).

Renato

Quote:
Originally Posted by Sonicman_ View Post
I know how to place pushpins and play with latitude/longitude and everything, but I am so far unable to determine the territory name for a pushpin I just placed (using VBA).

I have about 50 territories in the united states and would like to place a pushpin, determine it's territory and delete the pushpin.

Determining the territory is my issue. I tried doing a search but all of those who have posted this question did not get any answer. I hope i'll be more successful !

Thank you for your help it will be greatly appreciated.

Sonicman
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
determine, pushpin, recently, territory


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
Determine if Map has been closed BirdIslander MapPoint 2006/2009 Discussion 1 12-07-2005 02:33 PM
Extracting the corresponding Territory to a PushPin Location jpendegraft MapPoint 2006/2009 Discussion 3 08-13-2005 03:06 AM
Which Territory is a Pushpin located? johnweidauer MapPoint 2006/2009 Discussion 1 07-31-2005 11:46 AM
Active-X : Way to determine if pushpin is on diplayed map? Anonymous MapPoint 2006/2009 Discussion 1 08-02-2004 10:01 AM
Is there a way to determine the minimum distance b.... Anonymous MapPoint 2006/2009 Discussion 1 01-22-2002 05:45 AM


All times are GMT -5. The time now is 03:35 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


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