MapPoint Forums

MapForums

Community of VE/MapPoint Users and Developers




printing: the parameter is incorrect if not geoPrintMap

This is a discussion on printing: the parameter is incorrect if not geoPrintMap within the MapPoint 2006/2009 Discussion forums, part of the Map Forums category; Hi, I'm trying to print with following code (prntDlg is a printer dialog form). The problem is in the geoPrintArea, ...


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 11-17-2005
Senior Member
Black Belt
 
Join Date: Nov 2004
Posts: 2,122
printing: the parameter is incorrect if not geoPrintMap

Hi,

I'm trying to print with following code (prntDlg is a printer dialog form). The problem is in the geoPrintArea, if it is 0 (geoPrintMap) then it print ok, but any other value (1..5) gives: 'the parameter is incorrect' error. Anyone know what the problem could be ?

Code:
            MP.ActivePrinter = prntDlg.SelectedPrinter.Items[prntDlg.SelectedPrinter.SelectedIndex].ToString();
            MP.ActiveMap.PrintOut("",
                                  prntDlg.Title.Text,
                                  (int)prntDlg.Count.Value,
                                  (GeoPrintArea)prntDlg.GeoPrint,
                                  (GeoPrintQuality)prntDlg.Quality,
                                  (GeoPrintOrientation)prntDlg.Orientation,
                                  prntDlg.Collate.Checked,
                                  prntDlg.Legend.Checked,
                                  prntDlg.Overview.Checked,
                                  prntDlg.Faxable.Checked);
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 11-17-2005
Winwaed's Avatar
Mapping-Tools.com
Red Belt
 
Join Date: Feb 2004
Posts: 899
Blog Entries: 10
Wilfried,

I've used this option before so I know it works. Have you tried the names of the enum types (geoPrintDirections, geoPrintHighlightedPlaces, geoPrintMap, geoPrintSelectedArea, geoPrintStripMaps, geoPrintTurnByTurn and geoPrintFullPage) instead?


Richard
__________________
Winwaed Software Technology LLC
http://www.winwaed.com
See http://www.mapping-tools.com for MapPoint Tools
Pre-Order MapPoint 2009 today: http://www.mapping-tools.com/mappoint2009
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 11-17-2005
Senior Member
Black Belt
 
Join Date: Nov 2004
Posts: 2,122
Hi Richard,

I tryed one of them and _yes_ it works Thanks. Still find it strange wy the typecast wont work. It works for all other parameters.
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 11-18-2005
Junior Member
White Belt
 
Join Date: Aug 2003
Posts: 10
Quote:
Originally Posted by Wilfried
Hi Richard,

I tryed one of them and _yes_ it works Thanks. Still find it strange wy the typecast wont work. It works for all other parameters.
What type of variable is GeoPrint? I'm guessing that whatever it is, isn't compatible with the cast. 0 will always cast fine. But if the cast is losing precision (or adding), then that will mess things up.

Joel
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #5 (permalink)  
Old 11-19-2005
Senior Member
Black Belt
 
Join Date: Nov 2004
Posts: 2,122
Hi,

integer, so must be valid, but to be sure I should try it again, because this method gives 'the parameter is incorrect' error when there is a print option set that should not be there, eg route if there is no route. And by the time I asked this question I did not check for these things.
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
geoprintmap, incorrect, parameter, printing


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
"The parameter is incorrect" Jaba MapPoint 2006/2009 Discussion 9 02-15-2005 02:44 PM
Incorrect locations? harris00 MapPoint 2006/2009 Discussion 1 05-25-2004 11:40 PM
byte parameter Anonymous MapPoint 2006/2009 Discussion 0 05-22-2004 06:12 AM
How can i find address by passing Lat/Lon as parameter? joesebi MapPoint 2006/2009 Discussion 1 07-09-2003 10:10 AM
link data wizard won't let me use parameter queries Anonymous MapPoint 2006/2009 Discussion 7 08-23-2002 11:14 AM


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