Filters.?.tab only work with real accounts.

But you can work around it.
Specify the real address in the filter tab file.
In the yahoo.tab make it:
"cmd.exe /c G:\Xmail\scripts\yahoo.cmd" "@@FILE" "@@RCPT"

Then in the yahoo.cmd test for the RCPT=alias
like this:

@Echo off
setlocal
if not "%~2"=="[EMAIL PROTECTED]" exit 0
set logfile=G:\Xmail\yahoo\yahoo.log
....... etc

adding the one IF line, the batch will exit if not for the specified alias.
Also change the last "exit 0" to "exit 4" to quietly delete message in
xmail.

The other way to do this is to make the RCPT not an alias.
Do this.
remove the alias from webmaster,
create \mailroot\cmdaliases\thebatchfile.com\dummy.tab
add this one line to the file:
"external"[tab]"0"[tab]"60"[tab]"cmd.exe /c G:\Xmail\scripts\yahoo.cmd"
"@@FILE" "@@RCPT"[crlf]

you can still make the changes described for the first option, but the user
check becomes optional because xmail has done this for you.
Also I think the exit 4 becomes optional because there is no "mailbox" like
command in the cmdaliases tab file.

This has the effect of making ALL email to [EMAIL PROTECTED] go through
yahoo.cmd, because you can't specify the from address in the tab files.

Rob :-)

> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] Behalf Of thebatchfile
> Sent: Wednesday, October 08, 2003 11:01 PM
> To: [EMAIL PROTECTED]
> Subject: [xmail] Re: Can no one help on this?
>
>
>
> This does work now thanks to you but 2 things are happening. It
> still leaves
> a copy in the users inbox ,and it only works if in the
> filters.in.tab there
> is a specified user and not an alias. I would like it to work for an alias
> of an already established account.
>
> Here is what was in the yahoo.log
> "\\?\G:\Xmail\MailRoot\spool\20\7\mess\1316782304476.2260.tbf02"
> G:\Xmail\MailRoot\spool\20\7\mess\1316782304476.2260.tbf02
>
> My setup:
>
>
>
> In G:\Xmail\MailRoot\filters.in.tab I have
>
> "*" "*" "0.0.0.0/0" "0.0.0.0/0" "avfilter.tab"
>
> "*" "*" "0.0.0.0/0" "0.0.0.0/0" "flavs.tab"
>
> "*" "*" "0.0.0.0/0" "0.0.0.0/0" "xscanner.tab"
>
> "*" "*" "0.0.0.0/0" "0.0.0.0/0" "copyin.tab"
>
> "[EMAIL PROTECTED]" "[EMAIL PROTECTED]" "0.0.0.0/0" "0.0.0.0/0"
> "yahoo.tab"  < this works
>
> "[EMAIL PROTECTED]" "[EMAIL PROTECTED]" "0.0.0.0/0" "0.0.0.0/0"
> "yahoo.tab"   < doesnt not work (dummy is an alias under webmaster)
>
>
>
> In G:\Xmail\MailRoot\filters\yahoo.tab I have
>
> "cmd.exe /c G:\Xmail\scripts\yahoo.cmd" "@@FILE"
>
> In the G:\Xmail\scripts\yahoo.cmd I have
>
> @Echo off
> setlocal
> set logfile=G:\Xmail\yahoo\yahoo.log
> set xmailfile=%~1
> if "%xmailfile:~0,4%"=="\\?\" set xmailfile=%xmailfile:~4%
> echo %1 %xmailfile%>>%logfile%
> copy %xmailfile% G:\Xmail\yahoo\
> endlocal
> exit 0
>
> I just need for an example any email that comes from [EMAIL PROTECTED] to
> what ever user I specify or if no user is specified, to go to a folder and
> thats the only place. Not a copy from an inbox. Know what I mean.
>
>
>
> ----- Original Message -----
> From: "Rob Arends" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Tuesday, October 07, 2003 10:49 PM
> Subject: [xmail] Re: Can no one help on this?
>
>
> >
> > I was thinking this was the case,
> > I came across this just last week,
> >
> > Here is the fix on winnt (2k/xp) based systems (not win9x)
> >
> > G:\Xmail\scripts\yahoo.cmd
> > --------------------------
> > 1 @Echo off
> > 2 setlocal
> > 3 set logfile=G:\Xmail\yahoo\yahoo.log
> > 4 set xmailfile=%~1
> > 5 if "%xmailfile:~0,4%"=="\\?\" set xmailfile=%xmailfile:~4%
> > 6 echo %1 %xmailfile%>>%logfile%
> > 7 copy %xmailfile% G:\Xmail\yahoo\
> > 8 endlocal
> > 9 exit 0
> >
> > (Obviously remove the first column of line numbers)
> > Line 1 is optional
> > line 2 makes sure all variables are only within this CMD,
> >        not global (in case the cmd runs simultaneously)
> > line 3 your log file
> > line 4 put the first parameter into a env-variable, because
> >        then we can do basic string manipulation
> >        note that I've used %~1 not %1, this removes quotes
> >        from the string.
> > line 5 if the first 4 chars are "file://?/" then strip the
> first 4 chars.
> > line 6 log the info. (if you had done at least an
> >        "echo %1 >>log.txt" you would have seen what was being
> >        passed to the CMD and realised that the string was
> >        invalid in a CMD environment.
> > line 7 copy the file
> > line 8 return to global environment (optional since the CMD is about to
> > exit)
> > line 9 set the return code to xmail (optional since zero is the default)
> >
> > for full details of the string manipulations, run CMD, then type HELP or
> > HELP SET.
> >
> > Rob :-)
> >
> >
> > > -----Original Message-----
> > > From: [EMAIL PROTECTED]
> > > [mailto:[EMAIL PROTECTED] Behalf Of Tracy
> > > Sent: Friday, October 03, 2003 1:30 PM
> > > To: [EMAIL PROTECTED]
> > > Subject: [xmail] Re: Can no one help on this?
> > >
> > >
> > > You are probably running into a pathing issue. XMail versions 1.16 and
> > > later (possibly 1.15 as well, I can't recall now), use the \\?\ prefix
> on
> > > path names, to allow paths longer than 260 characters. This
> is perfectly
> > > legal in calls to the Win32 API, but it doesn't work well for
> > > command line
> > > apps.
> > >
> > > Likely you'll need to write some code to accomplish your task
> - the code
> > > would need to check for \\?\ on the beginning of the path, and
> > > strip those
> > > four characters if they are found.
> > >
> > > The code can be C, Perl, or whatever you're comfortable with. But I
> don't
> > > know of a way to do it using batch files... Rexx could probably
> > > handle it -
> > > but if you're going to go to that much trouble, might as well use Perl
> or
> > > VBScript.
> > >
> > > At 22:26 10/3/2003, webmaster wrote:
> > >
> > >
> > > >good bone.. Heres the deal
> > > >win2k platform
> > > >xmail 1.17
> > > >
> > > >using yahoo for an example/testing
> > > >
> > > >G:\Xmail\MailRoot\filters\yahoo.tab
> > > >"cmd.exe /c G:\Xmail\scripts\yahoo.cmd"[tab]"@@FILE
> > > >
> > > >G:\Xmail\scripts\yahoo.cmd
> > > >copy %1 G:\Xmail\yahoo\
> > > >
> > > >FILTERS.IN.TAB
> > > >
> > > >"*"     "*"     "0.0.0.0/0"     "0.0.0.0/0"     "avfilter.tab"
> > > >"*"     "*"     "0.0.0.0/0"     "0.0.0.0/0"     "flavs.tab"
> > > >"*"     "*"     "0.0.0.0/0"     "0.0.0.0/0"     "xscanner.tab"
> > > >"*"     "*"     "0.0.0.0/0"     "0.0.0.0/0"     "copyin.tab"
> > > >"[EMAIL PROTECTED]"[tab]"[EMAIL PROTECTED]"[tab]"0.0.0.0
> > > /0"[tab]"0.
> > > >0.0.0/0"[tab]"yahoo.tab"
> > > >
> > > >it does not copy the email destined for mcostilow to the yahoo dir
> > > >
> > > >-----Original Message-----
> > > >From: [EMAIL PROTECTED]
> > > >[mailto:[EMAIL PROTECTED] Behalf Of Tracy
> > > >Sent: Thursday, October 02, 2003 8:38 PM
> > > >To: [EMAIL PROTECTED]
> > > >Subject: [xmail] Re: Can no one help on this?
> > > >
> > > >
> > > >OK, as I understand it, you need to intercept email to a particular
> local
> > > >user, is that right? Also, I'm assuming you're using version
> > > 1.16 or later?
> > > >
> > > >If so, then add a line to the filters.in.tab file:
> > > >
> > > >"*"     "<local-user>"  "0.0.0.0/0"     "0.0.0.0/0"
> "PDF-Filter.tab"
> > > >
> > > >Note that "<local-user>" should be the email address of the
> > > local user you
> > > >want to intercept mail for. If that user is [EMAIL PROTECTED], then
> > > that entry
> > > >should look like "[EMAIL PROTECTED]"
> > > >
> > > >If you need to limit the check to a certain sender, replace the first
> "*"
> > > >with the email address of the sender - if the sender is
> [EMAIL PROTECTED],
> > > >then replace "*" with "[EMAIL PROTECTED]"
> > > >
> > > >Then, in PDF-Filter.tab, do your processing on that email.
> After you've
> > > >finished processing it, you can use a return code from the filter to
> > > >specify whether or not the mail is delivered to the user.
> > > >
> > > >At 21:33 10/3/2003, webmaster wrote:
> > > >
> > > >
> > > > >throw me a bone. I know that. Thats what im trying to do with no
> luck.
> > > > >
> > > > >-----Original Message-----
> > > > >From: [EMAIL PROTECTED]
> > > > >[mailto:[EMAIL PROTECTED] Behalf Of Davide Libenzi
> > > > >Sent: Thursday, October 02, 2003 8:27 PM
> > > > >To: [EMAIL PROTECTED]
> > > > >Subject: [xmail] Re: Can no one help on this?
> > > > >
> > > > >
> > > > >
> > > > >On Fri, 3 Oct 2003, webmaster wrote:
> > > > >
> > > > > > Huh?  Im confused. The whole deal is I need for emails that
> > > come from
> > > > > > datafax.net to go to a certain folder on the server that is
> > > shared on a
> > > > > > windows network.
> > > > > >
> > > > > > If I can get that to happen I will use mpack or unpack to
> > > extrack the
> > > >pdf
> > > > > > inside the email..
> > > > > >
> > > > > > I need the email that is directed at a certain user to not touch
> his
> > > > >inbox,
> > > > > > but go directly to the share and get extracted for all to
> > > see the pdf.
> > > > >This
> > > > > > email comes weekly.
> > > > >
> > > > >You need a filter to do that.
> > > > >
> > > > >
> > > > >
> > > > >- Davide
> > > > >
> > > > >-
> > > > >To unsubscribe from this list: send the line "unsubscribe xmail" in
> > > > >the body of a message to [EMAIL PROTECTED]
> > > > >For general help: send the line "help" in the body of a message to
> > > > >[EMAIL PROTECTED]
> > > > >
> > > > >
> > > > >-
> > > > >To unsubscribe from this list: send the line "unsubscribe xmail" in
> > > > >the body of a message to [EMAIL PROTECTED]
> > > > >For general help: send the line "help" in the body of a message to
> > > > >[EMAIL PROTECTED]
> > > >
> > > >
> > > >-
> > > >To unsubscribe from this list: send the line "unsubscribe xmail" in
> > > >the body of a message to [EMAIL PROTECTED]
> > > >For general help: send the line "help" in the body of a message to
> > > >[EMAIL PROTECTED]
> > > >
> > > >-
> > > >To unsubscribe from this list: send the line "unsubscribe xmail" in
> > > >the body of a message to [EMAIL PROTECTED]
> > > >For general help: send the line "help" in the body of a message to
> > > >[EMAIL PROTECTED]
> > >
> > >
> > > -
> > > To unsubscribe from this list: send the line "unsubscribe xmail" in
> > > the body of a message to [EMAIL PROTECTED]
> > > For general help: send the line "help" in the body of a message to
> > > [EMAIL PROTECTED]
> > >
> > >
> >
> > -
> > To unsubscribe from this list: send the line "unsubscribe xmail" in
> > the body of a message to [EMAIL PROTECTED]
> > For general help: send the line "help" in the body of a message to
> > [EMAIL PROTECTED]
> >
> >
>
> -
> To unsubscribe from this list: send the line "unsubscribe xmail" in
> the body of a message to [EMAIL PROTECTED]
> For general help: send the line "help" in the body of a message to
> [EMAIL PROTECTED]
>
>

-
To unsubscribe from this list: send the line "unsubscribe xmail" in
the body of a message to [EMAIL PROTECTED]
For general help: send the line "help" in the body of a message to
[EMAIL PROTECTED]

Reply via email to