Expansion of WebHub-HTML syntax when macro start open-parentil followed by dot

Question came in today:

I am stuck with the (~. problem.
In stringvars it seems to add a dot if we put a macro into an input field.
When we then have a page and the macro (~.aaaa~) and do a pwebapp.send then the macro does NOT get expanded.

I have tried and do the expanding twice e.g. pwebapp.expand() and then pwebapp.send and the macro gets expanded.

You have certainly thought about this. Is there a function like pwebapp.send which expands all macros also the ones with the dot e.g. (~.aaaa~)

See function TwhApplication.BuiltInEvent in htWebApp.pas.
That defines the default way that built-in macro expansion happens.

Lines 900-901

        if (Result[i] = TwhChar(MacroStart[1])) and
          (Result[i + 1] = TwhChar(MacroStart[2])) and (Result[i + 2] <> '.')

That is where the rule about the dot ‘.’ happens.

Almost all the Send methods run through here such that content within MacroStart and MacroEnd gets expaned.

There are some Send methods that end in ‘Imm’ meaning Immediate.
pWebApp.SendStringImm

The immediate send does NOT expand parentils.

Hope that helps.

Ann