MapPoint Forums

MapForums

Community of VE/MapPoint Users and Developers




Automatic Bar/Pie Charts (with Data from SQLServer)

This is a discussion on Automatic Bar/Pie Charts (with Data from SQLServer) within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; Hi, with MP 2004 / VB.Net I generate a JPEG-File that shows our shop locations on a map. This works ...


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-26-2004
Junior Member
White Belt
 
Join Date: Mar 2004
Posts: 10
Automatic Bar/Pie Charts (with Data from SQLServer)

Hi,

with MP 2004 / VB.Net I generate a JPEG-File that shows our shop locations on a map. This works fine. Creating pushpinsets is also no problem - if this should be necessary.

Where I haven't found a solution yet, is to show a bar/pie chart instead of every pushpin-symbol that illustrates e.g. sales data of the specific shop which are available in sqlserver. The problem is not to get the data from sqlserver but to show it at the locations on the map. Is it a property of the pushpins? Is it possible to map the already positioned pushpins with the sales data by the shop id, or have the adress data be read together with the sales data?

Anybody has a sample code?

Thanks in advance.
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-26-2004
Eric Frost's Avatar
Senior Member
Black Belt
 
Join Date: Jul 1992
Posts: 2,470
Blog Entries: 1
Here's the sample code for DisplayDataMap in the Help file.. this is a very versatile method, there's a lot in the documentation.

Code:
  Sub CreateShadedAreaMapUsingMapPointDemographics()
    Dim objApp As New MapPoint.Application
    Dim objDataSet As MapPoint.DataSet
    Dim objDataMap As MapPoint.DataMap
    Dim objField As MapPoint.Field

    'Set up application and objects to use
    objApp.Visible = True
    objApp.UserControl = True
    Set objDataSet = objApp.ActiveMap.DataSets.GetDemographics()
    Set objField = objDataSet.Fields("Households (1980)")

    'Create the data map, and give it a name
    Set objDataMap = _
      objDataSet.DisplayDataMap(geoDataMapTypeShadedArea, _
      objField, geoShowByRegion1, geoCombineByDefault, _
      geoRangeTypeDiscreteEqualRanges, geoRangeOrderDefault, 15)
    objDataMap.LegendTitle = "State Households"
  End Sub
Eric
__________________
~ Now taking orders for MapPoint 2009 ~
~
~ Upgrade to MapForums Plus membership ~
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-27-2004
Junior Member
White Belt
 
Join Date: Mar 2004
Posts: 10
... thank you eric, i've also found that, but what i did not find is how to get my data from e.g. a recordset (containing street, zip code, city and sales amount) into the ActiveMap.DataSets and then make sure all records are getting displayed -> because of multiple matches with the adress information.

any solution for that or is there another way?
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-27-2004
Eric Frost's Avatar
Senior Member
Black Belt
 
Join Date: Jul 1992
Posts: 2,470
Blog Entries: 1
What I would recommend is putting a lat/lon on each of your records first and store this in the database. Then map by lat/lon instead of address. Does this help?

Eric
__________________
~ Now taking orders for MapPoint 2009 ~
~
~ Upgrade to MapForums Plus membership ~
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
automatic, bar or pie, charts, data, sqlserver


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
Help Please!!! With Mapping information to pie charts DCM MapPoint 2006/2009 Discussion 3 12-16-2005 10:33 AM
How can I change charts size? julior MapPoint 2006/2009 Discussion 0 03-12-2004 05:22 AM
Automatic Zip Code tak_ibi MapPoint 2006/2009 Discussion 0 08-11-2003 05:29 PM
UDL to SQLServer doesn't work (C#) Anonymous MapPoint 2006/2009 Discussion 0 04-03-2003 06:50 AM
how to reset the automatic zoom function nglovier MapPoint 2006/2009 Discussion 1 12-05-2002 02:10 PM


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