Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDevelopment and...Development and...DNN Platform (o...DNN Platform (o...DotNetNuke...Sendmail with multiple attachments?DotNetNuke...Sendmail with multiple attachments?
Previous
 
Next
New Post
2/2/2009 8:25 AM
 

I am building a module which contains several textfields in a form.
At the end of the form there must be 2 fields where users can upload a file (probably .doc).
All the fields must be send in an email.

These filefields are not the problem, neigther is the email function.(DotNetNuke...Sendmail)

The problem is this: How do I attach both files in 1 email?
I have tried comma-seperated (, or ; or :), Array's, but nothing seems to work.(filename is String)

Can anyone help me on this?

 
New Post
2/2/2009 3:45 PM
 

there are sendmail overloads accepting arrays, others accept a string only, but you can submit a list of file names, separated by pipe "|" symbol.

HTH


Cheers from Germany,
Sebastian Leupold

dnnWerk - The DotNetNuke Experts   German Spoken DotNetNuke User Group

Speed up your DNN Websites with TurboDNN
 
New Post
2/3/2009 1:04 AM
 

Thnx! I've tried a lot of characters, but not "|".


 
New Post
2/3/2009 9:10 AM
 

It is indeed working now, except...

When I try to attach "network"-files (files from networkdrives), the mail is incorrect. The Sendmail probably only works with local files?
Is it possible that I first have to upload the files to the server, and then attach them?
And then afterwards delete them from the "temp"- directory?

Thnx in advance!

 
New Post
2/3/2009 11:25 AM
 

Keep in mind that an asp.net application such as DNN is not running under the same user as you are. It's a totally separate profile. That means a couple things. First off if you're logged and have a N: drive mounted that doesn't mean your web server knows anything about that drive, that is only known to your session. If you are addressing network resources from a web application you'll need to use a UNC (i.e. \\servername\sharename\filename). Next problem is credentials. You may be able to see something on a share, but your web application is likely running under ASPNET or NETWORK SERVICE that is a machine local account, not what you logged in as. That means of you need to access a network resource that needs a domain or workgroup id you'll need to change the identity of your application. The easiest way to do that is to create a new "service" userid in the domain, give it permissions to the shares in question, and change your application pool to use that userid/password.

This isn't specific to sendmail, it'll happen anytime in ASP.NET you try to access a network resource.

You can move the files to the server in the folder path with your application, but remember the web application still needs to have permissions to access those files if it's going to reference them even if it is only to copy them locally.

 
Previous
 
Next
HomeHomeDevelopment and...Development and...DNN Platform (o...DNN Platform (o...DotNetNuke...Sendmail with multiple attachments?DotNetNuke...Sendmail with multiple attachments?


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out