ImageGear for C and C++ on Windows v19.1 - Updated
IG_gui_save_page_dlg
API Reference Guide > GUI Component API Reference > GUI Component Functions Reference > Save Functions > IG_gui_save_page_dlg

Shows the file save dialog and returns the file name, the page number to save or replace, and also the format identifier if the file format of the image is detected.

Declaration:

 
Copy Code
BOOL ACCUAPI IG_gui_save_page_dlg (
        HWND hWnd, 
        LPCHAR lpTitle, 
        HIGEAR hIGear, 
        LPAT_LMODE lpnSaveList, 
        UINT nSListSize, 
        LPAT_IGGUI_SAVEFILE_INFO lpSFInfo 
);

Arguments:

Name Type Description
hWnd HWND Handle of the parent window.
lpTitle LPCHAR Dialog title.
hIGear HIGEAR Pointer to the HIGEAR.
lpnSaveList LPAT_LMODE Format list. If NULL the function generates list of available formats to use in the save dialog as a file names filter.
nSListSize UINT Format list size.
lpSFInfo LPAT_IGGUI_SAVEFILE_INFO Pointer to AT_IGGUI_SAVEFILE_INFO structure that provides information on how the image file should be saved.

Return Value:

If the user specifies parameters and clicks the OK button, the return value is non-zero. If the user cancels or closes the dialog box or an error occurs, the return value is zero.

Supported Raster Image Formats:

All pixel formats supported by ImageGear for C and C++.

Sample:

Color, Image Processing, JPEG, Medical, Palette Edit, Pixel Access, Print, Annotation, Filters, ImageClean, Multimedia

Example:

 
Copy Code
#include "IG_gui_common.h"
AT_IGGUI_SAVEFILE_INFO                          SFInfo;
HIGEAR                          hIGear;
LPAT_DIB                        lpDIB
memset( &SFInfo, 0, sizeof(SFInfo) );
IG_image_DIB_pntr_get( hIGear, &lpDIB );
IG_gui_save_page_dlg( hWnd, NULL, hIGear, NULL, 0, &SFInfo );