I am answering my own post here as I got a solution to this from another list I posted 
to.  This batch file will read a file as input and add a forward.ima file (or anything 
if you change the data portion) to the user (folder) named in the first column.

Here's the .bat file: (named fwdparse
@echo off
@rem File: fwdparse.cmd
if "%MailAddrParser%" equ "" goto docommand
if exist %1 goto gotdir
md %1
:gotdir
pushd %1
echo %2 > forward.ima
popd
goto exit
:docommand
set MailAddrParser=processing
for /F "eol=; tokens=1,2" %%i in (%1) do call fwdparse %%i %%j
rem or, to hard-wire the data file name:
rem for /F "eol=; tokens=1,2" %%i in (fordata.txt) do call fwdparse %%i %%j
set MailAddrParser=
:exit

sample data file 'fwdtest.txt:
joe_blow  [EMAIL PROTECTED]
jane_blow  [EMAIL PROTECTED]

Invoke as:
   C:\>fwdparse fwdtest.txt
or hard-wire the data file name into the command file where indicated and simply 
execute the command file. As written, the delimiter between the directory name and 
address can be a space or a tab, and lines in the data file with a semicolon in the 
first position will be ignored.

bob
________________________________________________________
From: bob mcgregor on Fri, Nov 10, 2000 10:54 AM
Subject: adding the forward.ima via batch
To: IMailList
Hi,

We are converting to iMail from another mail system and will convert somewhat slowly.  
What I'd like to do is load all of our current users to iMail via LDAPER which works 
great and then disable their account.
I then want to create a forward.ima file for each of them that will forward any mail 
that gets sent to the iMail server to their existing server until we enable their 
account.  The forward.ima does work for disabled accounts..

question:  Does anyone have a bat file or a load routine that can read a file of 
usernames and create the forward.ima file in the users mailbox?  If you do, do you 
mind sharing???

TIA, bob
Please visit http://www.ipswitch.com/support/mailing-lists.html
to be removed from this list.

An Archive of this list is available at:
http://www.mail-archive.com/imail_forum%40list.ipswitch.com/

Reply via email to