Community of VE/MapPoint Users and Developers
This is a discussion on Closing Without Saving A territory map within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; I am using the following to close without saving. MappointControl1.ActiveMap.Saved = True MappointControl1.CloseMap The above works great except when a ...
| |||||||
| Register | Blogs | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| |||
| Closing Without Saving A territory map MappointControl1.ActiveMap.Saved = True MappointControl1.CloseMap The above works great except when a territory map has been opened. Then on closing we are getting the 'Save Map' popup which should be disabled. The code I am using to open the territory map is listed below. Set objmap = MappointControl1.ActiveMap With objmap.DataSets Set objDataSet = .ImportTerritories(CSVFileName, , geoCountryUnitedKingdom, , geoImportExcelA1) End With I have tried using the 'Quit' and I am still getting the window popup. So my questions are 1) Is there anything special about how to close a territory 2) I was thinking about deleting the dataset before closing the map but the code listed below comes up the error; 'The requested set does not exist Set objDataSet = objmap.DataSets.ImportData(CSVFileName) Set objRecordset = objDataSet.QueryAllRecords For Each objDataSet In objmap.DataSets objDataSet.Delete Next Thanks in advance |
| |||
|
Hi, I have no idea wy it not should word with a terrain map, this looks like a bug to me. However you could do a few workarounds. - use SaveAs() and save the map - send a 'N' key to the window I think the first one is the most proper to do
__________________ rgds, Wilfried Mestdagh www.mestdagh.biz MapPoint coding demo Order MapPoint 2009 with Routing and User Tools Spreadsheet |
| |||
|
I have found the MSDN documentation for the BeforeClose event to be incorrect. It says "Occurs before the map closes. If the map has been changed, this event occurs before the user is asked to save changes." I found that this event occurs after the user is asked to save changes, which defeats the whole purpose of it. How frustrating!!! MSDN documentation http://msdn.microsoft.com/library/de...eforeClose.asp |
| |||
|
Hi, Indeed frustrating ! However I did not ever used one of these events. I set the closed to true when user colse map. there s a lot of events to react on withou using the mapoont ones.
__________________ rgds, Wilfried Mestdagh www.mestdagh.biz MapPoint coding demo Order MapPoint 2009 with Routing and User Tools Spreadsheet |
![]() |
| Tags |
| closing, map, saving, territory |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
| |
| ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| MapPoint crashs after closing the application | Elbarto | MapPoint 2006/2009 Discussion | 12 | 12-30-2006 10:47 PM |
| HELP!!! Saving map and pushpins... | phrozzy | MapPoint 2006/2009 Discussion | 2 | 05-30-2006 01:54 PM |
| Disabling closing of MapPoint? | MD2000 | MapPoint 2006/2009 Discussion | 1 | 05-09-2005 05:57 PM |
| Closing: MapPoint process stilll running | MD2000 | MapPoint 2006/2009 Discussion | 4 | 04-29-2005 09:58 AM |
| Closing without saving | Mudrover | MapPoint 2006/2009 Discussion | 1 | 01-30-2005 08:49 AM |