2
Answers

attach files using list box

Avinash Yoganand

Avinash Yoganand

14y
1.8k
1
i have a windows form where in i have to attach multiple files. I want to select those files using list box & attach & then send them as attachments through mail. Please guide me with the code.

First of all is it possible to do in windows forms. & Also is it possible to do in web application as well. If it is possible kindly guide in this regard.

Thanks in advance,
Avinash
Answers (2)
0
Bhabani Prasad

Bhabani Prasad

NA 1.4k 36.2k 10y
You just include the exception details as it will be easier to find the detailed error
0
Rajagopalan R V

Rajagopalan R V

NA 422 33.2k 10y
Sorry Can't Get Meaning For Your Above Post Please Can You Explain it Clearly
0
Jasmine Nagrecha

Jasmine Nagrecha

NA 180 4.2k 10y
i need to keep ssl=false, and defaultcredentials is =false. ideally, these settings should help. but i guess its something related to machine configuration
0
Rajagopalan R V

Rajagopalan R V

NA 422 33.2k 10y
Hi.,

Had You Allow Permissions in IIS

If Not Check With Below Method

Go to IIS
IIS---->
Default SMTP Virtual Server (Right Click) ----> Properties ----> Access ----> Relay ----> All Except the List Below (Radio Button) Select that And Click Ok And then Execute Your Code

If U Got Solution With this Mark it Has Accepted

Or Else Please Post The Error

With Regards..,

R.V.Rajagopalan
0
Yadlapalli Srikanth

Yadlapalli Srikanth

NA 238 51.6k 10y
Please share the sample code and also do the following settings

smtpClient.UseDefaultCredentials = false;
smtpClient.EnableSsl = true;