MapPoint Forums

MapForums

Community of VE/MapPoint Users and Developers




Demographic and Imported recordset

This is a discussion on Demographic and Imported recordset within the Development forums, part of the MapPoint 2006/2009 Discussion category; Is it possible to create a recordset that contains both the Mappoint demographic data and data that I import? Background ...


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

Register Blogs FAQ Members List Calendar Search Today's Posts Mark Forums Read
  2 links from elsewhere to this Post. Click to view. #1 (permalink)  
Old 10-18-2007
Junior Member
White Belt
 
Join Date: Oct 2007
Posts: 1
Demographic and Imported recordset

Is it possible to create a recordset that contains both the Mappoint demographic data and data that I import?

Background - I've created an Excel application that 1) imports customer data 2) creates drive time zones for our sales representative 3) exports the customer data within the drive time zone back to Excel. I just want to add the size of the zip code to the export.

Thanks.

-------------------------------------------------------------------


Private Sub CommandButton1_Click()

Set oApp = CreateObject("MapPoint.Application.NA.11")
oApp.Visible = True
Set objMap = oApp.NewMap
Dim objDataSet As MapPoint.DataSet

Dim objRecordset As MapPoint.Recordset
Dim objField As MapPoint.Field
Dim objPin As MapPoint.Pushpin
Set objDataSet = objMap.DataSets.ShowImportWizard
objDataSet.Symbol = 33
'start reading on row 2 of spreadsheet
nReadRow = 2
nShapeIndex = 1
nExportRow = 2

Do
szZip = Worksheets("Sheet1").Cells(nReadRow, 4)
fdrivetime = Worksheets("Sheet1").Cells(nReadRow, 5)
nColor = AssignColor(Worksheets("Sheet1").Cells(nReadRow, 6))
Set objLoc = objMap.FindAddressResults(, , , , szZip)(1)
Set objPin = objMap.AddPushpin(objLoc, Worksheets("Sheet1").Cells(nReadRow, 1))
Symbol = 205
' objMap.DataSets.ZoomTo
Set objshape = objMap.Shapes.AddDrivetimeZone(objLoc, fdrivetime * geoOneMinute)
objMap.Shapes.Item(nShapeIndex).Fill.Visible = True
objMap.Shapes.Item(nShapeIndex).ZOrder (geoSendBehindRoads)
objMap.Shapes.Item(nShapeIndex).Fill.ForeColor = nColor
objMap.Shapes.Item(nShapeIndex).Line.ForeColor = vbBlack
objMap.Shapes.Item(nShapeIndex).Line.Weight = 1
objMap.Shapes.Item(nShapeIndex).SizeVisible = False
' objshape.Select

Set objRecordset = objDataSet.QueryShape(objshape)
objRecordset.MoveFirst
Do Until objRecordset.EOF
For Each objField In objRecordset.Fields

Worksheets("Sheet2").Cells(nExportRow, 1) = objPin.Name
Worksheets("Sheet2").Cells(nExportRow, 7) = objRecordset.Fields("ZIP")
Worksheets("Sheet2").Cells(nExportRow, 2) = objRecordset.Fields("State")
Worksheets("Sheet2").Cells(nExportRow, 3) = objRecordset.Fields("County")
Worksheets("Sheet2").Cells(nExportRow, 4) = objRecordset.Fields("CL")
Worksheets("Sheet2").Cells(nExportRow, 5) = objRecordset.Fields("PL")
Worksheets("Sheet2").Cells(nExportRow, 6) = objRecordset.Fields("Size")
Worksheets("Sheet2").Cells(nExportRow, = fdrivetime
Next objField
objRecordset.MoveNext

nExportRow = nExportRow + 1
Loop
nShapeIndex = nShapeIndex + 1
nReadRow = nReadRow + 1
Loop Until Worksheets("Sheet1").Cells(nReadRow, 1) = ""
End Sub
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


LinkBacks (?)
LinkBack to this Thread: http://www.mapforums.com/demographic-imported-recordset-6584.html

Posted By For Type Date
hghosted » Blog Archive » Demographic and Imported recordset This thread Pingback 10-22-2007 05:19 AM
Reverse Geocoding, Pt. III - MapPoint Articles - MP2K Magazine This thread Refback 10-19-2007 11:42 AM

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
Labeling Imported Data Gary98363 MapPoint 2006/2009 Discussion 2 05-23-2007 01:59 PM
sequence of imported data changes Harv MapPoint 2006/2009 Discussion 1 05-27-2003 04:09 PM
Deriving a recordset from a mappoint recordset RichardHayes MapPoint 2006/2009 Discussion 0 09-06-2002 02:44 AM
ADO recordset Monique Wish List 0 08-14-2002 09:35 AM
Can someone who has successfully imported external.... Anonymous MapPoint 2006/2009 Discussion 1 04-24-2002 12:17 PM


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

Skiing Package
For that perfect skiing package visit Holiday Hypermarket. Search for ski holidays according to your specific requirements online. Holiday Hypermarket makes it simple and rapid.

Travel Agent
Travel Counsellors was voted UK's Best Travel Agent at the Guardian Unlimited travel awards.

Holidays Italy
Book your holidays in Italy. Italy has a great climate and the beaches to go with it. Book a great deal for great value online at dealchecker.co.uk.

Antigua Holidays
We have the most popular Antigua holidays at highly competitive prices at The Holiday Place. Book a break in sunny Antigua today.

Cheap Spain Holidays
Stay well informed when you are searching for cheap holidays online. For useful advice on when to book cheap Spain holidays make sure you look on ulookubook.com

Inclusive late deals
For inclusive late deals, check out your options at Travel.co.uk and have fun!

Holidays to Cyprus
Take the plunge into a world of summer splendour! Find information on holidays to Cyprus online, only at On The Beach.


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