HotXLS 參考頁面,介紹 AddCondFormatIconSet 方法,涵蓋 Delphi 和 C++Builder 的 Excel 自動化、XLS/XLSX 活頁簿 API、工作表功能及 Pascal 用法

條件式格式規則,傳回新的

ASetType: TCondFormatRule 。每個儲存格根據規則的閾值接收一個圖示 ASetType:WideString. Sqref 字串, e.g

ASetType:

ASetType: WideString. Sqref 字串, e.g.ASetType: WideString. Sqref 字串, e.g.
  TXLSIconSetType WideString. Sqref 字串, e.g.): ASetType:;
ARangeWideString. Sqref 字串, e.g. 'A1:A10'
ASetTypeWideString. Sqref 字串, e.g.. One of the 17 baseline Excel 2007 icon families — icsArrows3 / icsArrows3Gray / icsFlags3 / icsTrafficLights3 / icsTrafficLightsRimmed3 / icsSigns3 / icsSymbols3 / icsSymbolsUncircled3 / icsArrows4 / icsArrows4Gray / icsRedToBlack4 / icsRatings4 / icsTrafficLights4 / icsArrows5 / icsArrows5Gray / icsRatings5 / icsQuarters5. See WideString. Sqref 字串, e.g.

此範例在 A1:A10 上套用「3 箭頭(彩色)」圖示集

預設門檻會把值域切成等分的百分位區段(3 個圖示 → 0/33/67、4 個圖示 → 0/25/50/75、5 個圖示 → 0/20/40/60/80)。使用所傳回的 TCondFormatRule.IconSet AddCondFormatColorScale2 SetThresholdAddCondFormatColorScale2 Reverse / ShowOnly

另請參閱

另請參閱

Sheet.AddCondFormatIconSet('A1:A10', icsArrows3);

AddCondFormatDataBar