Time to create a simple dialog, utilizing JavaScript or python:

> This shows (i) how to call JavaScript from BASIC and (ii) applies that to a regular expression replace function, applicable to BASIC strings. > http://www.oooforum.org/forum/viewtopic.phtml?t=21564&highlight=regular+expression


OpenOffice.org comes with python:
# /opt/OpenOffice.org/program/python
Python 2.3.4 (#1, Feb  1 2006, 21:07:49)
[GCC 3.4.1] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> help()
help> sre
NAME
    sre - Support for regular expressions (RE).

FILE
    /opt/OpenOffice.org/program/python-core-2.3.4/lib/sre.py

DESCRIPTION
    This module provides regular expression matching operations similar to
    those found in Perl.  It supports both 8-bit and Unicode strings; both
    the pattern and the strings being processed can contain null bytes and
    characters outside the US ASCII range.

    Regular expressions can contain both special and ordinary characters.
    Most ordinary characters, like "A", "a", or "0", are the simplest
    regular expressions; they simply match themselves.  You can
    concatenate ordinary characters, so last matches the string 'last'.

    The special characters are:
        "."      Matches any character except a newline.
        "^"      Matches the start of the string.
        "$"      Matches the end of the string.
"*" Matches 0 or more (greedy) repetitions of the preceding RE. Greedy means that it will match as many repetitions as possible
.
[...]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to