RVIsURL, RVIsEmail Functions

<< Click to display table of contents >>

RVIsURL, RVIsEmail Functions

These function return True if the string is URL or e-mail address.

Unit [VCL/FMX] RVFileFuncs / fmxRVFileFuncs.

function RVIsURL(const s: TRVUnicodeString): Boolean;

function RVIsEmail(const s: TRVUnicodeString): Boolean;

(introduced in version 10; changed in version 18)

First, RVIsURL calls RVIsCustomURL. If it returns False, RVIsURL checks for the following prefixes:

http://

ftp://

file://

gopher://

mailto:

https://

news:

telnet:

wais:

www.

ftp.

In TRichView, this function is used to ignore URLs in live spelling check, or to find which links are local links when loading RTF and DocX files. Besides, it is used in demo projects and in RichViewActions.

See also: how to create a chat window.