This section covers, in detail, the functions available with the BiThumbnail.OCX.
Description This method initializes a thumbnail control.
Usage RetVal = [BiThumbnail.] InitThumbnail parentWnd menuStyle controlStyle windowStyle
Remarks RetVal LONG Thumbnail handler.
parentWnd LONG Handler of parent window
menuStyle LONG Code of menu style.
controlStyle LONG Code of control style.
windowStyle LONG Code of window style.
Available menu style codes (user can add these constants):
MS_EMPTY Does not show any items.
MS_ALL Show all menu items.
MS_FILE Show file menu.
MS_VIEW Show view menu.
MS_OPTIONS Show options menu.
MS_HELP Show help menu.
MS_FILE_OPEN Show file/open menu.
MS_FILE_DELETE Show file/delete menu.
MS_FILE_BROWSE Show file/browse... menu.
MS_FILE_EXIT Show file/exit menu.
MS_VIEW_STATUSBAR Show view/statusbar menu.
MS_OPTIONS_DISPLAY Show options/display menu.
MS_OPTIONS_SELECTION Show options/selection menu.
MS_HELP_ABOUT Show help/about... menu.
Available control style codes (user can add these constants):
CS_EMPTY Show just thumbnail control
CS_ALL Show all of controls
CS_DIRECTORY_COMBOBOX Show directoty combo
CS_TREECONTROL Show tree control
CS_CANCEL_BUTTON Show cancel button
CS_OPEN_BUTTON Show open button
CS_STATUSBAR Show statusbar
Available window style codes (user can add these constants):
WS_ENABLE_ALL All these styles are enabled
WS_DISABLE_CAPTION Disable the caption bar
WS_DISABLE_RESIZE Disable the resizability
WS_DISABLE_MINIMIZE_BUTTON Disable the minimize button
WS_DISABLE_MAXIMIZE_BUTTON Disable the maximize button
WS_DISABLE_SYSMENU Disable system menu
WS_DISABLE_BORDER Disable border
See Also DeleteThumbnail Method
Description This method deletes a thumbnail control.
Usage [BiThumbnail.] DeleteThumbnail thumbHandler
Remarks thumbHandler LONG Thumbnail handler.
See Also InitThumbnail Method
Description This method displays a thumbnail control.
Usage RetVal = [BiThumbnail.] DisplayThumbnailDlg thumbHandler
Remarks RetVal LONG 1 if click on Ok button or Open menu.
thumbHandler LONG Thumbnail handler.
See Also CreateModelessThumbnailDlg, ShowModelessThumbnailDlg
CreateModelessThumbnailDlg Method
Description This method creates a modeless thumbnail dialog. In this case, if the user clicks on the Open button it generates a ThumbnailOpenImagesEvent event.
Usage RetVal = [BiThumbnail.] CreateModelessThumbnailDlg thumbHandler parentWnd
Remarks RetVal LONG 1 if creation of the window is successful.
thumbHandler LONG Thumbnail handler.
parentWnd LONG Handle to the parent window.
See Also DisplayThumbnailDlg, ShowModelessThumbnailDlg
ShowModelessThumbnailDlg Method
Description This method shows or hides the modeless thumbnail dialog.
Usage RetVal = [BiThumbnail.] ShowModelessThumbnailDlg thumbHandler showWnd
Remarks RetVal LONG 1 if show / hide of the window is successful.
thumbHandler LONG Thumbnail handler.
showWnd LONG true - show window; false - hide window.
See Also DisplayThumbnailDlg, CreateModelessThumbnailDlg
Description This method gets the code of last generated error.
Usage RetVal = [BiThumbnail.] GetLastThumbnailError thumbHandler
Remarks RetVal LONG Error code.
thumbHandler LONG Thumbnail handler.
Available error codes:
EC_NOERRORS No error occurs.
See Also GetLastThumbnailErrorString
GetLastThumbnailErrorString Method
Description This method gets the string format of last generated error.
Usage RetVal = [BiThumbnail.] GetLastThumbnailErrorString thumbHandler
Remarks RetVal BSTR Error string.
thumbHandler LONG Thumbnail handler.
Available error codes:
“No errors” No error occurs.
See Also GetLastThumbnailError
Description This method gets the number of selected images.
Usage RetVal = [BiThumbnail.] GetNumOfSelectedItems thumbHandler
Remarks RetVal LONG Number of selected images.
thumbHandler LONG Thumbnail handler.
See Also GetSelectedItem
Description This method gets the indexed file from list of selected images.
Usage RetVal = [BiThumbnail.] GetSelectedItem thumbHandler index
Remarks RetVal BSTR String that contains file neme with path.
thumbHandler LONG Thumbnail handler.
index LONG Index in list of selected images.
See Also GetNumOfSelectedItems
Description This method gets the current directory.
Usage RetVal = [BiThumbnail.] GetCurrentDirectory thumbHandler
Remarks RetVal BSTR String that contains path of current directory.
thumbHandler LONG Thumbnail handler.
See Also SetCurrDirectory
Description This method gets the code of selection mode.
Usage RetVal = [BiThumbnail.] GetSelectionMode thumbHandler
Remarks RetVal LONG Code of selection mode.
thumbHandler LONG Thumbnail handler.
Available selection mode codes:
SM_SINGLESELECTION It allows just single selection.
SM_MULTISELECTION It allows multiselection.
See Also SetSelectionMode
Description This method gets the code of the legal selection types. If the selection option is set to SO_ALLIMAGEFILES, the Thumbnail dialog will display just these type of images. In the menu Options/Selection… iShow special image files is where these types will be shown.
Usage RetVal = [BiThumbnail.] GetLegalSelectionTypes thumbHandler
Remarks RetVal LONG Code of legal selection types.
thumbHandler LONG Thumbnail handler.
Available legal selection types codes (user can add these constants):
SO_ALLIMAGEFILES Display all of image files
SO_TIFF_FILE Display tiff files
SO_PCX_FILE Display pcx files
SO_DCX_FILE Display dcx files
SO_GIF_FILE Display gif files
SO_BMP_FILE Display bmp files
SO_CLP_FILE Display clp files
SO_WMF_FILE Display wmf files
SO_EMF_FILE Display emf files
SO_FAX_FILE Display fax files
SO_TGA_FILE Display tga files
SO_JPEG_FILE Display jpeg files
SO_CALS_FILE Display cals files
SO_PNG_FILE Display png files
SO_PDF_FILE Display pdf files
See Also SetLegalSelectionTypes
Description This method gets the code of selection options.
Usage RetVal = [BiThumbnail.] GetSelectionOptions thumbHandler
Remarks RetVal LONG Code of selection options.
thumbHandler LONG Thumbnail handler.
Available selection options codes (user can add these constants):
SO_ALLFILES Display all of files
SO_ALLIMAGEFILES Display all of image files
SO_TIFF_FILE Display tiff files
SO_PCX_FILE Display pcx files
SO_DCX_FILE Display dcx files
SO_GIF_FILE Display gif files
SO_BMP_FILE Display bmp files
SO_CLP_FILE Display clp files
SO_WMF_FILE Display wmf files
SO_EMF_FILE Display emf files
SO_FAX_FILE Display fax files
SO_TGA_FILE Display tga files
SO_JPEG_FILE Display jpeg files
SO_CALS_FILE Display cals files
SO_PNG_FILE Display png files
SO_PDF_FILE Display pdf files
See Also SetSelectionOptions
Description This method gets the code of sort by.
Usage RetVal = [BiThumbnail.] GetSortBy thumbHandler
Remarks RetVal LONG Code of sort by.
thumbHandler LONG Thumbnail handler.
Available sort by codes:
SB_NAME, Sort by file name
SB_TYPE, Sort by file extension
SB_SIZE, Sort by size of file
SB_DATE Sort by last modification date
See Also SetSortBy
Description This method gets the x coordinate of left-top angle of window.
Usage RetVal = [BiThumbnail.] GetWindowPositionX thumbHandler
Remarks RetVal LONG x coordinate of left-top angle of window.
thumbHandler LONG Thumbnail handler.
See Also GetWindowPositionY
GetWindowWidth, GetWindowHeight
SetWindowPosition, SetWindowSize, SetWindowRect
Description This method gets the y coordinate of left-top angle of window.
Usage RetVal = [BiThumbnail.] GetWindowPositionY thumbHandler
Remarks RetVal LONG y coordinate of left-top angle of window.
thumbHandler LONG Thumbnail handler.
See Also GetWindowPositionX,
GetWindowWidth, GetWindowHeight
SetWindowPosition, SetWindowSize, SetWindowRect
Description This method gets width of window.
Usage RetVal = [BiThumbnail.] GetWindowWidth thumbHandler
Remarks RetVal LONG Width of window.
thumbHandler LONG Thumbnail handler.
See Also GetWindowPositionX, GetWindowPositionY
GetWindowHeight
SetWindowPosition, SetWindowSize, SetWindowRect
Description This method gets height of window.
Usage RetVal = [BiThumbnail.] GetWindowHeight thumbHandler
Remarks RetVal LONG Height of window.
thumbHandler LONG Thumbnail handler.
See Also GetWindowPositionX, GetWindowPositionY
GetWindowWidth,
SetWindowPosition, SetWindowSize, SetWindowRect
Description This method gets the thumbnail loading mode.
Usage RetVal = [BiThumbnail.] GetLoadingMode thumbHandler
Remarks RetVal LONG Thumbnail loading mode.
thumbHandler LONG Thumbnail handler.
Available thumbnail loading codes:
LT_LOWQUALITY load thumbnails in low quality, but it's fast
LT_HIGHQUALITY load thumbnails in high quality, but it's slow
LT_MIXED it loads thumbnails in low quality, and then fresh those in high quality
See Also SetLoadingMode
Description This method sets path of current directory.
Usage [BiThumbnail.] SetCurrDirectory thumbHandler path
Remarks thumbHandler LONG Thumbnail handler.
path STRING String that contains path of current directory.
See Also GetCurrentDirectory
Description This method sets selection mode.
Usage [BiThumbnail.] SetSelectionMode thumbHandler selMode
Remarks thumbHandler LONG Thumbnail handler.
selMode LONG Code of selection mode.
Available selection mode codes:
SM_SINGLESELECTION It allows just a single selection.
SM_MULTISELECTION It allows multiselection.
See Also GetSelectionMode
Description This method sets the code of the legal selection types. If the selection option is set to SO_ALLIMAGEFILES, the Thumbnail dialog displays just these type of images. In the menu Options/Selection…Show special image files these types is where this is shown.
Usage [BiThumbnail.] SetLegalSelectionTypes thumbHandler legalSelTypes
Remarks thumbHandler LONG Thumbnail handler.
legalSelTypes LONG Code of the legalselection types.
Available legal selection types codes (user can add these constants):
SO_ALLIMAGEFILES Display all of image files
SO_TIFF_FILE Display tiff files
SO_PCX_FILE Display pcx files
SO_DCX_FILE Display dcx files
SO_GIF_FILE Display gif files
SO_BMP_FILE Display bmp files
SO_CLP_FILE Display clp files
SO_WMF_FILE Display wmf files
SO_EMF_FILE Display emf files
SO_FAX_FILE Display fax files
SO_TGA_FILE Display tga files
SO_JPEG_FILE Display jpeg files
SO_CALS_FILE Display cals files
SO_PNG_FILE Display png files
SO_PDF_FILE Display pdf files
See Also GetLegalSelectionTypes
Description This method sets selection options.
Usage [BiThumbnail.] SetSelectionOptions thumbHandler selOpt
Remarks thumbHandler LONG Thumbnail handler.
selOpt LONG Code of selection options.
Available selection options codes (user can add these constants):
SO_ALLFILES Display all of files
SO_ALLIMAGEFILES Display all of image files
SO_TIFF_FILE Display tiff files
SO_PCX_FILE Display pcx files
SO_DCX_FILE Display dcx files
SO_GIF_FILE Display gif files
SO_BMP_FILE Display bmp files
SO_CLP_FILE Display clp files
SO_WMF_FILE Display wmf files
SO_EMF_FILE Display emf files
SO_FAX_FILE Display fax files
SO_TGA_FILE Display tga files
SO_JPEG_FILE Display jpeg files
SO_CALS_FILE Display cals files
SO_PNG_FILE Display png files
SO_PDF_FILE Display pdf files
See Also GetSelectionOptions
Description This method sets sort by mode.
Usage [BiThumbnail.] SetSortzBy thumbHandler sortBy
Remarks thumbHandler LONG Thumbnail handler.
sortBy LONG Code of sort by mode.
Available sort by codes:
SB_NAME, Sort by file name
SB_TYPE, Sort by file extension
SB_SIZE, Sort by size of file
SB_DATE Sort by last modification date
See Also GetSortBy
Description This method sets the coordinates of left-top angle of window.
Usage [BiThumbnail.] SetWindowPosition thumbHandler posX posY
Remarks thumbHandler LONG Thumbnail handler.
posX LONG x coordinate of the window position.
posY LONG y coordinate of the window position.
See Also GetWindowPositionX, GetWindowPositionY,
GetWindowWidth, GetWindowHeight
SetWindowSize, SetWindowRect
Description This method sets the size of window.
Usage [BiThumbnail.] SetWindowSize thumbHandler width height
Remarks thumbHandler LONG Thumbnail handler.
width LONG Width of the window.
height LONG Height of the window.
See Also GetWindowPositionX, GetWindowPositionY,
GetWindowWidth, GetWindowHeight
SetWindowPosition, SetWindowRect
Description This method sets the rectangle of window.
Usage [BiThumbnail.] SetWindowRect thumbHandler left top right bottom
Remarks thumbHandler LONG Thumbnail handler.
left LONG Minimal x coordinate of window.
top LONG Minimal y coordinate of window.
right LONG Maximal x coordinate of window.
bottom LONG Maximal y coordinate of window.
See Also GetWindowPositionX, GetWindowPositionY,
GetWindowWidth, GetWindowHeight
SetWindowPosition, SetWindowSize
SetEnablePopupMenu Method
Description This method sets enable or disable popup menu on thumbnail icons.
Usage [BiThumbnail.] SetEnablePopupMenu thumbHandler enable
Remarks thumbHandler LONG Thumbnail handler.
enable LONG 1 - enable, 0 - disable popup menu.
See Also
SetImageSize Method
Description This method sets the size of thumbnail images.
Usage [BiThumbnail.] SetImageSize thumbHandler width height
Remarks thumbHandler LONG Thumbnail handler.
width LONG Width of the thumbnail image.
height LONG Height of the thumbnail image.
See Also
SetCaptionText Method
Description This method sets the caption text of window.
Usage [BiThumbnail.] SetCaptionText thumbHandler captionText
Remarks thumbHandler LONG Thumbnail handler.
captionText STRING String that contains caption text.
See Also
Description This method sets the window icon.
Usage [BiThumbnail.] SetIcon thumbHandler hIcon
Remarks thumbHandler LONG Thumbnail handler.
hIcon LONG Icon handler.
See Also SetIconWithPath
Description This method sets the image which will be displayed during image is loading.
Usage [BiThumbnail.] SetUnloadedImage thumbHandler hBitmap
Remarks thumbHandler LONG Thumbnail handler.
hBitmap LONGLONG Bitmap handler.
See Also SetUnloadedImageWithPath
Description This method sets the image which will be displayed at thumbnail of nonimage files.
Usage [BiThumbnail.] SetIllegalImage thumbHandler hBitmap
Remarks thumbHandler LONG Thumbnail handler.
hBitmap LONGLONG Bitmap handler.
See Also SetIllegalImageWithPath
Description This method sets the window icon.
Usage [BiThumbnail.] SetIconWithPath thumbHandler path
Remarks thumbHandler LONG Thumbnail handler.
path STRING String that contains file path.
See Also SetIcon
SetUnloadedImageWithPath Method
Description This method sets the image which will be displayed during image is loading.
Usage [BiThumbnail.] SetUnloadedImageWithPath thumbHandler path
Remarks thumbHandler LONG Thumbnail handler.
path STRING String that contains file path.
See Also SetUnloadedImage
SetIllegalImageWithPath Method
Description This method sets the image which will be displayed at thumbnail of nonimage files.
Usage [BiThumbnail.] SetIllegalImageWithPath thumbHandler path
Remarks thumbHandler LONG Thumbnail handler.
path STRING String that contains file path.
See Also SetIllegalImage
Description This method sets the thumbnail loading mode.
Usage [BiThumbnail.] SetLoadingMode thumbHandler loadingType
Remarks RetVal LONG Thumbnail loading mode.
thumbHandler LONG Thumbnail handler.
loadingType LONG Thumbnail loading type.
Available thumbnail loading codes:
LT_LOWQUALITY load thumbnails in low quality, but it's fast
LT_HIGHQUALITY load thumbnails in high quality, but it's slow
LT_MIXED it loads thumbnails in low quality, and then fresh those in high quality
See Also GetLoadingMode