On Saturday, July 2, 2005, at 15:59:15 [UTC-0500] (Saturday, July 2, 2005
22:59 my local time) Mary Bull wrote:

>> You can make many things using such trick, e.g., repair threads, use HTML
>> templates, modify different parts of message or even substitute or delete
>> attachments.

> I am very intrigued. Would it be practical to set this up as a Quick
> Template, rather than a filter in the Sorting Office?

I suppose it is impossible to use such mechanism in templates, because they
act only on message text in the editor. First operation in the filter is
exporting message to Unix mailbox file. This can be done only manually or
using filter action. This is only first reason which prevent automated
message modification using template.

Another reason may be inability to edit all header fields by template, even
using macros with regular expressions. Again, it can be done manually in good
text editor, for example in TextPad, but the we loose all automation.

> In other words, a one or two click editing mechanism, such as the one
> Dwight Corrin envisioned, so that the message body could be edited
> without changing the References used in threading?

What about filter triggered by one simple keyboard shortcut? This is more
universal solution because filters can process entire message with its original
structure, attachments, etc. I use several filter sets prepared especially
for different tasks of such kind and they save my time.

For example, more than two year ago I built filters for re-threading
messages. They are resident in Marck's repository [1], but due to new
filtering mechanism implemented in The Bat! those filters are now
"old-fashioned". Now I am using modified filters with export/import/modify
features. They are attached in one text file (description of their action is
unchanged and available at [1]).

> Also, to automatically put a "message-altered" notification into the
> process?

Yes, this is quite easy task in the filter template described in my previous
message. Of course, you can first define "X-Message-Altered" field in the
header configuration panel and then set it by the filter template in
redirected and modified message before sending. However, this additional
message header field can be set immediately in that filter, by including simple
line: "X-Message-Altered: <any text here>". That is the power of The Bat!
filtering mechanism.

__________
 [1] http://cgi.silverstones.com/library.php#rethread+messages

Attachments:
 1. Add_Remove_Reference.txt

-- 
Best regards,
Zygmunt Wereszczynski
(Using The Bat! v3.5.36 on Windows 2000 5.0 Build 2195 Service Pack 4
with BayesIt! 0.8.1)
$$$$ TB! Message Filter $$$$
beginFilter
UID: [85FC1D80.01C4C0A7.06BD38FA.52EB88E6]
Name: Add_Reference
Filter: [EMAIL PROTECTED]
ExportMessage OverwriteExist FmtUnix filename D:\5CUnix_Msg.txt 
filenamerelative D:\5CUnix_Msg.txt
ExportMessage OverwriteExist FmtText filename D:\5Cexport.msg filenamerelative 
D:\5Cexport.msg template 
%_OldMsg(%Put\3D\22D:\5CUnix_Msg.txt\22)%-\0D\0A%SetPattRegExp\3D\22(?ismU)(.*)(^Subject:.*\5Cs*.*\5Cn)(\5Cw.*?)\22%RegexpBlindMatch(%_OldMsg)%-\0D\0A%Subpatt(1)%Subpatt(2)In-Reply-To:\20%Clipboard\0D\0AReferences:\20%Clipboard\0D\0A%Subpatt(3)%-\0D\0A
RunExternal Wait CmdLine 
C:\5CProgram\20Files\5CThe\20Bat!\5Cthebat.exe\20/IMPORTF\3DIMPORT;X;R;W;I\3D\22D:\5Cexport.msg\22
RunExternal RunHidden Wait CmdLine D:\5Cremove.bat
MoveMessage folder \5C\5C\5CTrash
IsManual
IsActive
IsHotkey
IsSendQueue
endFilter


$$$$ TB! Message Filter $$$$
beginFilter
UID: [8D62EE00.01C4C0A7.2B2D3918.3A1B017D]
Name: Remove_Reference
Filter: [EMAIL PROTECTED]
ExportMessage OverwriteExist FmtUnix filename D:\5CUnix_Msg.txt 
filenamerelative D:\5CUnix_Msg.txt
ExportMessage OverwriteExist FmtText filename D:\5Cexport.msg filenamerelative 
D:\5Cexport.msg template 
%_OldMsg(%Put\3D\22D:\5CUnix_Msg.txt\22)%-\0D\0A%SetPattRegExp\3D\22(?ismU)(.*)(^References:.*\5Cs*.*\5Cn)(\5Cw.*?)\22%RegexpBlindMatch(%_OldMsg)%-\0D\0A%_NewHeader\3D\22%Subpatt(1)%Subpatt(3)\22%-\0D\0A%SetPattRegExp\3D\22(?ismU)(.*)(^In-Reply-To:.*\5Cs*.*\5Cn)(\5Cw.*?)\22%RegexpBlindMatch(%_NewHeader)%-\0D\0A%Subpatt(1)%Subpatt(3)\0D\0A\0D\0A%SetPattRegExp\3D\22(?ism)\5Cn\5Cn(.*)\22%RegexpMatch(%_OldMsg)%-\0D\0A
RunExternal Wait CmdLine 
C:\5CProgram\20Files\5CThe\20Bat!\5Cthebat.exe\20/IMPORTF\3DIMPORT;X;R;W;I\3D\22D:\5Cexport.msg\22
RunExternal RunHidden Wait CmdLine D:\5Cremove.bat
MoveMessage folder \5C\5C\5CTrash
IsManual
IsActive
IsHotkey
IsCheckRule
IsHotkeyOnly
IsSendQueue
endFilter


Content of the file D:\remove.bat:
------------------------------
DEL D:\Unix_Msg.txt
EXIT
________________________________________________________
 Current beta is 3.5.36 | 'Using TBBETA' information:
http://www.silverstones.com/thebat/TBUDLInfo.html
IMPORTANT: To register as a Beta tester, use this link first -
http://www.ritlabs.com/en/partners/testers/

Reply via email to