FILESASSOCIATIONDLGPARAMS

typedef struct _FILESASSOCIATIONDLGPARAMS 
{ 
   L_UINT uStructSize ; 
   L_TCHAR * pszFormats ; 
   L_TCHAR * pszSelectedExt ; 
   L_TCHAR * pszServerAppName ; 
   L_UINT32 uDlgFlags ; 
   LTCOMMDLGHELPCB pfnHelpCallback; 
   L_VOID *pHelpCallBackUserData ; 
} FILESASSOCIATIONDLGPARAMS, * LPFILESASSOCIATIONDLGPARAMS ; 

The FILESASSOCIATIONDLGPARAMS structure provides information used to initialize the dialog box created by the L_DlgFilesAssocition function. After the user closes the dialog box, this structure is updated with information about the user's selections.

Members

uStructSize

Size of this structure, in bytes. Use the sizeof operator to calculate this value.

pszFormats

Pointer to a buffer containing pairs of null-terminated strings, which represent the filter(s) to be associated or de-associated and the filter pattern. The last string in the buffer must be terminated by two NULL characters.

The first string in each pair is the display string that describes the filter (for example, "LEAD"), and the second string specifies the filter pattern (for example, "*.CMP").

To specify multiple filter patterns for a single display string, use a semicolon to separate the patterns (for example, "*.JPG;*.JPEG").

If pszFormats is NULL, the dialog box shows the default image file formats that LEADTOOLS support. Set this member to initialize the dialog.

For example, this member could be set to the following: "LEAD (*.cmp)\0*.cmp\0DICOM (*.dic)\0Windows Bitmap (*.bmp)\0*.bmp\0\0"

pszSelectedExt

Pointer to a buffer, containing null-terminated strings that represent the filters to initially be checked and associated. The last string in the buffer must be terminated by two NULL characters. Set this member to initialize the dialog. This member can be NULL.

For example, this member could be set to the following: "*.cmp\0*.dic\0*.bmp\0\0"

pszServerAppName

Pointer to a buffer containing a null-terminated string. This represents the "Programmatic Identifier" to be associated with the selected image type(s) when successfully exiting this dialog. The dialog assumes that the server application name has already been created before calling the dialog. For more information about creating a file association programmatic identifier, refer to the Microsoft Windows Win32 SDK documentation.

uDlgFlags

User interface flags for this dialog, which determine the layout and action of the dialog. Possible values are:

Value Meaning
DLG_FILESASSOCIATION_SHOW_CONTEXTHELP [0x00000001] Dialog should contain a context sensitive help icon.

pfnHelpCallback

Pointer to an optional help callback function. If you do not wish to provide help to this dialog, use NULL as the value of this parameter. To provide help to this dialog, use the function pointer as the value of this parameter. The callback function must adhere to the prototype described in LTCOMMDLGHELPCB.

pHelpCallBackUserData

Void pointer that you can use to pass one or more additional parameters that the callback function needs. To use this feature, assign a value to a variable or create a structure that contains as many fields as you need. Then, in this parameter, pass the address of the variable or structure, casting it to L_VOID *. The callback function, which receives the address in its own pHelpCallBackUserData parameter, can cast it to a pointer of the appropriate data type to access your variable or structure. If the additional parameters are not needed, you can pass NULL in this parameter.

Help Version 20.0.2020.4.2
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2020 LEAD Technologies, Inc. All Rights Reserved.

LEADTOOLS Common Dialog C API Help