MapPoint Forums

MapForums

Community of VE/MapPoint Users and Developers




using an excel record as a variable

This is a discussion on using an excel record as a variable within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; I export (programmatically) from excel to mappoint. There are, say, four fields: Order number; Name; Postcode; week number. This maps ...


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 02-07-2004
Senior Member
Black Belt
 
Join Date: Jul 2002
Posts: 5,138
using an excel record as a variable

I export (programmatically) from excel to mappoint.
There are, say, four fields: Order number; Name; Postcode; week number.
This maps fine.

I am trying to associate the week number of each record with a pushpin symbol number.
How do I use or access the individual records in the fields?

I have thoroughly searched your Q &A, picked up many tips, but no clues to solve this problem.

I am fairly new to programming.

I have tried to adapt this code but can only get field names.

Code:
Sub GetAllFieldNames()

  Dim objApp As New MapPoint.Application
  Dim objDataSet As MapPoint.DataSet
  Dim objFld As MapPoint.Field
  Dim strFldNames As String
  
  'Set up the application
  objApp.Visible = True
  objApp.UserControl = True
  
   'Let user create a data map
        objDataSet = _
          objApp.ActiveMap.DataSets.ShowImportWizard

  'Loop through all available fields for their names
  For Each objFld In objDataSet.Fields
    strFldNames = strFldNames & objFld.Name & vbCrLf
  Next
  
  MsgBox "DataSet field names: " & vbCrLf & strFldNames

End Sub
Using Mappoint 2004, Excel 2003, VB.Net

Many thanks
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 02-11-2004
Senior Member
Black Belt
 
Join Date: Jul 2002
Posts: 5,138
Try this

Dim objrecordset as MapPoint.Recordset
Set objrecordset = objDataSet.QueryAllRecords

Now you can access: objrecordset.Fields.Item(n).Value


Hope is usefull.
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 02-11-2004
Senior Member
Black Belt
 
Join Date: Jul 2002
Posts: 5,138
Marvellous—just what I was looking for.
Thanks very much for your help.
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
excel, record, variable


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
Are there any workarounds for the 10000 record lim.... Anonymous MapPoint 2006/2009 Discussion 2 03-23-2005 06:01 PM
Color coding locations by some variable, i.e. sales dollars mr4tno MapPoint 2006/2009 Discussion 0 02-17-2005 10:15 AM
gps record bchara MapPoint 2006/2009 Discussion 0 07-23-2004 08:31 AM
50,000-record limitation Anonymous MapPoint 2006/2009 Discussion 2 02-06-2004 11:41 AM
PUSHPIN RECORD LIMIT gsc1ugs Products: Pushpin Tool, Single State Mapper 2 03-07-2003 11:00 AM


All times are GMT -5. The time now is 12:02 PM.


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