QPx_SetAreaImageFile

QPx_SetAreaImageFile(areaRef; imagePath):error
areaRef Longint QPix area reference
imagePath Text Path to the image file
error Longint Error result

Displays an image file in a QPix plug-in area.

The QPix plug-in area is specified by areaRef. If areaRef is not a valid QPix plug-in area reference, qpx_paramErr is returned.

The image file to be displayed is specified by imagePath. If imagePath is empty, QPix presents a file selection dialog where the user can preview and select an image file. If the user selects a file, its full pathname is returned in imagePath, otherwise error qpx_userCancelErr is returned.

Example

  `Let the user select an image from disk
  `and display it in the plug-in area
 
C_LONGINT($error)
C_TEXT($imagePath)
 
$imagePath:=""
 
$error:=QPx_SetAreaImageFile (gQPixArea;$imagePath)
 
If ($error=qpx_noErr)
 
   `$imagePath contains the pathname of the selected file
 
End if

Related commands

QPx_GetAreaImageFile Gets the image file being displayed in a QPix area

QPix © Escape
Generated by QDoc 2.8 on Wed, Feb 17, 2010 17:44:21