[pmmail-list] HowTo Filter subject=(null)??

L.Willms pmmail-list@blueprintsoftwareworks.com
Fri, 18 Feb 2005 23:47:47 +0100 (MEZ)


On Fri, 18 Feb 2005 20:12:22 +0100, rooster wrote:

> Does not work with 
> --cut from the header-->
> From: " Idell" <2@>
> Subject:
> To: roostermail@...
> <---
> You see, subject is present, but simply nothing filled in.
> So, the often found case, null isnot empty.

   The problem is, that the equals sign in PMMfilter triggers does not 
mean equality, but inclusion, i.e. "is the string included in the 
'Subject:' header?". 
  
   But the null string is found everywhere ... they should have added 
the .size property not only for the M i.e. Message tag (for Body and 
Attachment it is valid, too, I think), but also for all other headers, 
like "Subject:" in this case. 

> >   You would look at "h.subject" and may achieve what you want by 
using 
> >the ICSL flags -e (match whole word), -b (the string must be at the 
> >beginning), -z (it must be at the end). 
> 
> Although I searched the help before, I did a second check, but I still 
can find nothing 
> helpfull for the above mentioned example.
 
   It doesn't work, since the null string is at the beginning and at the 
end, or don't know what. 

   Now, the solution would be the P or PROGRAM tag; with the P-tag one 
can use one's own program to search the message for anything and return 
the result in another file, who's name is passed by PMMail in a second 
parameter. 

   I have written such a filter in VBS, but I have not yet managed to 
get PMMail to execute WSCRIPT.EXE with my script as parameter. I get 
messages that the program could not be launched, or that the path 
specification for it would be wrong, or else. 

   The filter condition would look like this: 

   P.<wscript  x:\bpsw\pmmail\PMMfilter_Subject-size.VBS> = "0"

   In a test environment on the command line, it works fine, but not 
(yet) from the filter engine of PMMail. Maybe I have to make a full 
VB-EXE out of the script. The length of the value on the "Subject:" line 
is written in the first line of the file given as second parameter. 

   I have also made a generalized version which takes the label of the 
header line as a first parameter; the filter condition would be like 
this: 

   P.<wscript  x:\bpsw\pmmail\PMMfilter_Subject-size.VBS Subject:> = "0"

   I did not yet try it in PMMail ... 

   Is anybody competent from Blueprint Software Works here who can tell 
with certainty if and how such filter P-tags could work? 


Yours,
Lüko Willms
-----------------------------------------------
Frankfurt/Main