Creating Snapshot for Printing

May 17, 2013 at 7:52 AM
I want to print my map in high resolution, so that even if i print it on a 8x8 tarp the image will not get pixelized

is it possible?

heres my code

Dim myImage As New MapWinGIS.Image
Dim myExtents As MapWinGIS.Extents
myExtents = MainMap.Extents
myImage = MainMap.SnapShot(myExtents)

Dim xName As String
xName = Format(DateTime.Now, "MMddyyyy-hhmmss") & ".bmp"

myImage.Save("C:\SnapShot\" & xName, True, MapWinGIS.ImageType.BITMAP_FILE)

May 22, 2013 at 8:24 PM
I'm in the same point. The image that I see is all blurry.
May 23, 2013 at 8:31 PM
Edited May 23, 2013 at 8:38 PM
Hellow,

Try to use SnapShot2 or SnapShot3 function. These functions have like input parameter a resolution in pixels of image that function returns. Here is syntax of functions:

http://www.mapwindow.org/documentation/mapwingis4.8/class_ax_map.html#a8c0629f96ad8d5d583d70e235e663173

You must input the pixel width of image, and height will be compute by system with save aspect ratio.

I use these functions and they work properly for me.
May 27, 2013 at 3:16 AM
Hi Yankov!
Thank you very much,
that function do the trick!!
Here's the whole Procedure for my printing map/shape

This codes creates a snapshot and save it, then ask the user if he want to open the image

myExtents = MainMap.Extents
myImage = DirectCast(MainMap.SnapShot3(myExtents.xMin, myExtents.xMax, myExtents.yMax, myExtents.yMin, 8000), MapWinGIS.Image)
Dim xName As String
xName = Format(DateTime.Now, "MMddyyyy-hhmmss") & ".bmp"
myImage.Save("C:\SnapShot\" & xName, True, MapWinGIS.ImageType.BITMAP_FILE)
Dim xans As String
xans = MessageBox.Show("Open the Image?", "Open Image", MessageBoxButtons.YesNo, MessageBoxIcon.Question)
If xans = vbYes Then
 Shell("C:\windows\system32\mspaint.exe C:\Snapshot\" & xName, vbNormalFocus)
Else
 Exit Sub
End If