sendmail question

  • Thread starter CSGalloway@nc.rr.com
  • Start date
C

CSGalloway@nc.rr.com

Guest
I am using TCMD 10..... under XP Pro sp3

If I have too many attachments for an email as it comes back with "Command line too long" - besides making a ZIP and sending that instead how else can i send a large number of attachments?

========================echo . > "%USERPROFILE%\desktop\a.err"
for %fldr in (@dirlist.lst) (
Echo Working on %Fldr...
cdd "%fldr"
(for %fn in (*) set cAtt=%cAtt /A "%fn") >>&> "%USERPROFILE%\desktop\a.err"
echo sending email now...
sendmail %cAtt /d "someone@someplace.com" "%fldr" for your pleasure
unset cAtt
delay 120
cdd -
)
========================
 
CSGalloway@nc.rr.com wrote:
| I am using TCMD 10..... under XP Pro sp3
|
| If I have too many attachments for an email as it comes back with
| "Command line too long" - besides making a ZIP and sending that
| instead how else can i send a large number of attachments?
|
| =======================| echo . > "%USERPROFILE%\desktop\a.err"
| for %fldr in (@dirlist.lst) (
| Echo Working on %Fldr...
| cdd "%fldr"
| (for %fn in (*) set cAtt=%cAtt /A "%fn") >>&>
| "%USERPROFILE%\desktop\a.err" echo sending email now...
| sendmail %cAtt /d "someone@someplace.com" "%fldr" for your pleasure
| unset cAtt
| delay 120
| cdd -
| )
| =======================
You could keep track of the command line length (via the length of variable
cAtt) as you build cAtt, and use sendmail multiple times, until all files
are sent. I would also check the relevant RFC to learn about the limit on
the number of attachments, if any, a mail server and client are required to
deal with to conform to WWW standards. You may also neeed to check your
ISP's policies about the frequency at which it accepts outgoing mail.
--
HTH, Steve
 

Similar threads