Simplicty and flexibility!


New function in 8 - MemoMemoReplace() - Replace a tag with the content of a Memo (Ver 8.0.0.1282)

Started by DataEase
You will need to Sign In to be able to comment on the Blog!

New function in 8 - MemoMemoReplace() - Replace a tag with the content of a Memo (Ver 8.0.0.1282)

This is the complementary function of MemoReplace() which replace a tag in a Memo with the content of a string(255) or any other "normal" prism field/value.

The exciting bit about MemoMemoReplace() is that you can replace any tag with the content of a Memo Field.

So what is so exciting about this?

Just imagine. This way you can build a template like this:

[{header}]
[{customername}]
[{customeraddress}]
---------------------------------------------------------------------------------------------------------------------------------------------
[{body}]
---------------------------------------------------------------------------------------------------------------------------------------------

[{footer}]

and then you simply create a DQL like this...

for MyLetter with LetterID = getglobal("LetterID") ;
enter a record in NewLetters
dummy:=MemoMemoCopy(LetterBody, any Template with TemplateID=MyLetter TemplateID Template,1) ;
dummy:=MemoMemoReplace(LetterBody,"[{header}], any MyCompany with ComanpyID=MyLetter CompanyID Header) ;
etc...

I hope I haven't lost you now, but to make sure we will include it in a sample app and put it here.


Written by DataEase 08/05/13 at 13:46:40 Dataease [{8}]FIVE
DG3_BlogList