ISLOGICAL 函數

檢查某個值是否為邏輯值 (TRUE 或 FALSE),並傳回 TRUE 或 FALSE。

語法

ISLOGICAL(<value>)

參數

詞彙

定義

value

您想要測試的值。

屬性值/傳回值

如果此值為邏輯值,則為 TRUE,如果是 TRUE 或 FALSE 以外的任何值,則為 FALSE。

範例

下列三個範例會示範 ISLOGICAL 函數的行為。

//RETURNS: Is Boolean type or Logical
=IF(ISLOGICAL(true), "Is Boolean type or Logical", "Is different type")

//RETURNS: Is Boolean type or Logical
=IF(ISLOGICAL(false), "Is Boolean type or Logical", "Is different type")

//RETURNS: Is different type
=IF(ISLOGICAL(25), "Is Boolean type or Logical", "Is different type")

請參閱

其他資源

資訊函數 (DAX)