DataBasic Reference > Statements and Intrinsic Functions > A > ALPHA Function

Comment on this topic

Documentation Comments

Use this form to comment on this topic. You can also provide any general observations about the Online Documentation, or request that additional information be added in a future release.

RealityV15.1Online Documentation (MoTW) Revision 7

ALPHA Function (DataBasic) (m618703+alpha_f.htm)

To

Reality

Version

Topic

Submitted by

Company

Location

Email address

Comment

 

 

ALPHA Function

Searches a string for alphabetic characters.

Syntax

ALPHA(expression)

Syntax Elements

expression is any valid DataBasic expression or any string, substring, or value; expressed as a variable name, a value, or a string enclosed in quotes.

Comment

ALPHA returns a 1 (true) if expression is a string containing only upper and/or lower case alphabetic characters.

Examples

X = "123 WINDSOR AVE."
IF ALPHA(X) THEN PRINT "OKAY" ELSE GO 99

Returns a 0, because string X contains numeric values. Control transfers to statement 99.

CITY = "London"
IF ALPHA(CITY) THEN PRINT "ALL LETTERS" ELSE STOP

Returns a 1 and prints ALL LETTERS, because CITY contains only upper and lower case alphabetic characters.

RealityV15.1 (MoTW) Revision 7Comment on this topic