PrintDialogFit(Int32,IWin32Window) Method
Invokes the standard Windows Print dialog box, which allows you to select additional options or settings
and then to print the specified GdPicture image adjusting the picture size to the default paper size.
This method also allows to specify the top-level window that will own the modal dialog box.
public bool PrintDialogFit(
int ,
IWin32Window
)
public function PrintDialogFit(
: Integer;
: IWin32Window
): Boolean;
public function PrintDialogFit(
: int,
: IWin32Window
) : boolean;
public: bool PrintDialogFit(
int ,
IWin32Window*
)
public:
bool PrintDialogFit(
int ,
IWin32Window^
)
'Declaration
Public Overloads Function PrintDialogFit( _
ByVal As Integer, _
ByVal As IWin32Window _
) As Boolean
Parameters
- ImageID
- A unique image identifier of the GdPicture image representing the image in use.
- owner
- Represents the top-level window that will own the modal dialog box.
Return Value
true if the method has been followed successfully, otherwise false. Please use the
GdPictureImaging.PrintGetStat method to determine the reason for the printing failure.
Printing an image with the help of standard Windows Printer Dialog.
using (GdPictureImaging gdpictureImaging = new GdPictureImaging())
{
// Open an image file. An empty string allows the control to prompt for selecting a file.
int imageID = gdpictureImaging.CreateGdPictureImageFromFile("");
gdpictureImaging.PrintDialogFit(imageID, this);
// Release used resources.
gdpictureImaging.ReleaseGdPictureImage(imageID);
}