help files
Z505 | PasWiki | FUQ | Search | Main Docs | API Guide



[Overview][Constants][Types][Procedures and functions] Reference for unit 'strutils' (#rtl)

IfThen

Returns one of two strings, depending on a boolean expression

Declaration

Source position: line 0

function IfThen(

  AValue: Boolean;

  const ATrue: String;

  AFalse: String

):String;

function IfThen(

  AValue: Boolean;

  const ATrue: String

):String;

Arguments

AValue

  

Determines which of the two possibilities to take

ATrue

  

String to return if the expression evaluates as True.

AFalse

  

String to return if the expression evaluates as false. Default is the empty string.

Function result

Either AFalse or ATrue, depending on the expression.

Arguments

AValue

  

Determines which of the two possibilities to take

ATrue

  

String to return if the expression evaluates as True.

Function result

Either AFalse or ATrue, depending on the expression.

Description

IfThen returns ATrue if AValue is True, and returns AFalse if AValue is false.

Errors

None.

See also

AnsiMatchStr

  

Check whether a string occurs in an array of strings, observing case.

AnsiMatchText

  

Check whether a string occurs in an array of strings, disregarding case.

Notes

 No notes exist for this page yet. 





lufdoc, Powtils, fpc, freepascal, delphi, kylix, c/c++, mysql, cgi web framework docs, Z505