Help Center

CXpButton.SetIconFromFilemethod

Loads an icon from file and sets it as the image of the button.

Windowsmethoddocumented

Syntax

SUB SetIconFromFile (BYVAL pwszPath AS WSTRING PTR, BYVAL ImageState AS LONG, BYVAL fRedraw AS LONG = FALSE)

Parameters

NameDescription
pwszPathFull path of the icon's file.
ImageStateOne of the following values:
XPBI_NORMAL = 1, XPBI_HOT = 2, XPBI_DISABLED = 3
fRedrawOptional. CTRUE or FALSE (redraws the button to reflect the changes).

Description

Loads an icon from file and sets it as the image of the button.

Reference

  • Defined in AfxNova/CXpButton.inc:1298
  • Documented in Windows/Windows GUI/CXpButton Class.md
  • Topic: CXpButton Class