Email attachment from InputStream?

Discussion in 'ASP .Net' started by steven shingler, Jan 19, 2004.

  1. Hi all
    I've figured out how to add an attachment to a MailMessage object from
    a physical file on the hard disk, but would very much like to be able
    to do this using an InputStream instead. This could be particularly
    useful handling a PostedFile from a WebForm.
    Has anyone got any ideas on this?
    Best Wishes
    Steven
    steven shingler, Jan 19, 2004
    #1
    1. Advertising

  2. steven shingler

    Shiv Kumar Guest

    The MailAttachment class sadly only allows for physical files. So your only
    option is to save a file (convert the stream to a file) and then attach that
    file.

    --
    Shiv R. Kumar
    http://www.matlus.com
    Shiv Kumar, Jan 20, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Matthew Lenz
    Replies:
    0
    Views:
    508
    Matthew Lenz
    Feb 22, 2005
  2. Sam
    Replies:
    1
    Views:
    406
  3. peter x

    Email Attachment

    peter x, Mar 3, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    413
    Chad Z. Hower aka Kudzu
    Mar 3, 2004
  4. R
    Replies:
    5
    Views:
    2,084
    Kevin McMurtrie
    Mar 13, 2005
  5. ecureuil
    Replies:
    0
    Views:
    299
    ecureuil
    May 28, 2006
Loading...

Share This Page