Community of MapPoint and Bing Maps Users and Developers
This is a discussion on dataSet.zoomTo() within the MapPoint Desktop Discussion forums, part of the Map Forums category; Hi, the dataSet.zoomTo() function does'nt work, gives me an error. dataSets.zoomTo() works very well, zooming to show the symbols of ...
| |||||||
| Today's Posts | Twitter Feed | Register | Blogs | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| |||
| dataSet.zoomTo() the dataSet.zoomTo() function does'nt work, gives me an error. dataSets.zoomTo() works very well, zooming to show the symbols of all dataSets of the active map. How to zoom to a single dataSet? TIA Chris Werner |
| |||
| Wrong question, now: Add pushpins to a certain dataset?
Hi, investigating my code somewhat shows that dataSet.zoomTo() works very well too - if there are at least one pushpin in the dataset. But how to add pushpins to a certain dataset? Calling map.addPushpin() always adds the pushpin to a dataset called "My Pins" but I want to organize my added pushpins into different datasets. Any hint? TIA Chris Werner |
| |||
|
Hi Chris, I _think_ you can only add pushpins to the first dataset. However there are always workarounds Use the first dataset only as a temporary place to add your pushpins. After adding them you move them to the dataset of your choice. After the move they are automatically deleted from the primary dataset.
__________________ rgds, Wilfried Mestdagh www.mestdagh.biz www.comfortsoftware.be MapPoint coding demo Order MapPoint 2009 with Routing and User Tools Spreadsheet |
| |||
| Quote:
[C#] //See whether there is an existing datasetwith the same name object datasetName = "NorthWind Orders"; if(map.DataSets.Count > 0 && map.DataSets.get_Item(ref datasetName) != null) //If so, delete it map.DataSets.get_Item(ref datasetName).Delete( ); //Now create a new dataset MapPoint.DataSet dataset = map.DataSets.AddPushpinSet("whateverName"); //Find location MapPoint.Location location = null; try { //Get the location location = XXX;// put ur location anyway yo wish(lon/lat or // address) //Create a pushpin if(location != null) { MapPoint.Pushpin pushpin = map.AddPushpin(location, companyname); //Assign the contact name pushpin.Note = "Contact : " + customername; //Move to the pushpin dataset pushpin.MoveTo(dataset); } } catch { //Do some logging } i hope this can be a hint to the solution
__________________ KMB |
![]() |
| Tags |
| datasetzoomto |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Dataset rendering | Gianmaria | MapPoint Desktop Discussion | 3 | 06-09-2005 02:22 PM |
| How do you add records to a dataset | Anonymous | MapPoint Desktop Discussion | 1 | 05-03-2005 03:09 PM |
| ZoomTo Cropping | JRussell | MapPoint Desktop Discussion | 2 | 10-27-2003 10:47 AM |
| Another Question much simpler (zoomto stuff) | Dazzer | MapPoint Desktop Discussion | 1 | 09-24-2003 05:18 PM |
| If I have one dataset with 300 pushpins, how do i .... | Anonymous | MapPoint Desktop Discussion | 1 | 02-26-2002 12:52 PM |