Ben Langhinrichs

Photograph of Ben Langhinrichs

IBM Champion logo

E-mail address - Ben Langhinrichs







Recent posts

Wed 13 Feb 2019

Choices in your on-the-fly data retrieval



Wed 13 Feb 2019

@MQRY and on-the-fly data retrieval



Mon 11 Feb 2019

Formula language in a JavaScript world: JSON db lookups


May, 2019
SMTWTFS
   01 02 03 04
05 06 07 08 09 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31

Search the weblog





























Genii Weblog

Color coding formula language

Tue 21 Dec 2004, 09:39 PM



by Ben Langhinrichs
In response to yesterday's post Limits to cleverness, Julian Robichaux asked what I use to color code my formula language.  I must admit I use a really, really simple Midas agent:

Call rtitem.ConnectBackend(doc.Handle, "Body")
Set rtchunk = rtitem.DefineChunk("Everything")
rtchunk.TextWildcards = True
rtitem.HighlightFont = "Blue"
Call rtchunk.HighlightText("@*(")
rtitem.HighlightFont = "Black"
Call rtchunk.HighlightText("(")
rtitem.HighlightFont = "Magenta"
Call rtchunk.HighlightText(|"*"|)
rtitem.Save

See, it is easy if you have the right tools!  

And before anybody gets their knickers in a twist, it isn't very robust, and doesn't handle escaped quotes and the like.  Yawn!  It is quick and dirty and helps me get on to real work, which is what utilities are supposed to do.  Any of you want to write a more robust one, go for it.  The eval license is free and available, and I'll give you credit and such.  Yada, yada, yada.

Copyright © 2004 Genii Software Ltd.

What has been said:


262.1. Julian Robichaux
(12/22/2004 07:08 PM)

Cool. Any chance you could whip up a web implementation, so we could use it kind of like my LotusScript formatter on Joe Litton's site?

http://joelitton.net/A559B2/home.nsf/ConvertLS?OpenForm

- Julian


262.2. Pravin Machale
(02/23/2006 11:38 PM)

I am intersted in i have color formula book i wnt to entry that formula in software and in next time suppose i want some color formula serch for the software by giving name or no.is that type of software you provide.

best regards

pravin