Sending Data Collection Report As An Email Body

Jul 20, 2010

When you click on a button my program have to send a email where a report must be generated from table adapters from dataset. Now this report is not going to be displayed when the button is clicked, so it will be sent automatically by code which I have some part(see below). My questions are:

1. how can you generate or build a report without displaying it.
2.embeed this report or data collection from the table adapters as part of the body of the email

my email code so far is this:
mail.From = New MailAddress("qwerty@[URL]")
mail.To.Add(New MailAddress("qwerty@[URL]"))
mail.Subject = "test"
mail.Priority = MailPriority.Normal
Dim smpt As New SmtpClient
smpt.Host = [URL]
smpt.Port = 25
smpt.Credentials = New System.Net.NetworkCredential("qwerty@[URL]","****")) 'hehe not telling :P smpt.EnableSsl = True................

View 16 Replies


Similar Messages:

Data Controls :: Show Only Specific Columns And Hide Others When Sending GridView In Email Body

Jun 17, 2012

i have done sending gridview data  as excel  to mail, it is working fine

then  i had 5 columns in gridview but i want to send 4 column instead of 5 column.

protected void Button1_Click(object sender, EventArgs e)
{
fn_AttachGrid(); // here calling function to send mail gridview data as excel format
}

[Code]....

View 1 Replies

Data Controls :: Send Email With Data From Database In Email Body?

May 7, 2015

how to send email with database contents?

View 1 Replies

C# Converting Data In A Dataset Into Body Of An Email?

Dec 7, 2010

What's the best way to go from a dataset to the body of an email?

I have a .net console app to send email notification based on results of a stored proc and wanted to know how best to go from SQL data to Email body?

html body with colors and fonts would be best but plain text is also fine.

View 2 Replies

Web Forms :: Send Email With Arabic (Persian) Text In Email Body

May 7, 2015

I followed this link, it works fine with English Text. [URL] ....

My problem is when I am adding Arabic text to the message body it displays ???? format.

View 1 Replies

Web Forms :: How To Embed Chart In Email Body And Send Email

May 7, 2015

how to display Chart in Email body and excel attachment.

View 1 Replies

Data Controls :: Send Particular GridView Row As Email Body On Button Click

Feb 19, 2014

I am new to ASP.NET and have made a register page, 'get' which on submitting redirects to another page 'pick1' displaying the data in Gridview. In each row of the Gridview there are 'View' buttons which on clicking opens a pop-up page having 2 buttons 'send mail' and 'cancel'. On clicking 'send Mail' button, i want selected row of data to be sent by email instead of the entire gridview. Right now only the entire gridview data is coming to my mail. Also i want to attach a link to the email so that it redirects to the 'pick1' page again on clicking in email. How can I do it?

Below is my code for 'pick1' page:

protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
{
this.BindData();

[Code] ....

And the image of my 'pick1' and 'popup' page: 

View 1 Replies

Web Forms :: Sending URL From Mail Body

Dec 17, 2010

My application needs to send an email once the user has been registered. It should be able to send the new credentials, and a URL from the mail body. Every thing is working fine but I have few specifications that I am not able to reach.

1. I have multiple lines and I am not able to send a new line character from the mail body.
2. I should send them the link of my application which should be done using javascript (i guess) and i can not do it as well.

System.Net.Mail.
MailMessage mail =
new System.Net.Mail.MailMessage();
mail.Body =................

View 2 Replies

MVC :: Sending The Whole Collection To View?

Mar 7, 2011

mvc-ers in the Model i have a collection of Employees (EMPLOYEE_ID,
FIRST_NAME,
LAST_NAME,
MOBILE)

and i want to send particular fields from it to the view so in the Controller i write this code

[Code]....

how can i retrieve the collection in the view, should i create a class contains (e.EMPLOYEE_ID, Employee_Name)
and cast ViewData["Employees"] to it, or there is a trick?

View 4 Replies

SQL Server :: Getting A Email Deliver Status When Sending Email Using Msdb.dbo.sp_send_dbmail?

Aug 24, 2010

I have set a job in sql server 2008 to send reminder emails for product expiration. Now I want a report which will specify the list of the emails sent with the email status details like queued ,sent,delivered, failed.

I can fetch the emails that are sent by querying the like following

select * from sysmail_mailitems SM inner join sysmail_profile SP on SM.Profile_Id = SP.Profile_Id
and SP.Name ='ReminderProfile'

The problem is only getting a perfect status of email whether it is delived or failed. How I can get those status ?

View 2 Replies

Visual Studio 2005 - Sending An Email To User Input Email?

Feb 23, 2011

i have an aspx page, that takes in user data (name, number & email) after that information gets submitted to me, I need to send an email to their input email, with a message of confirmation.

View 1 Replies

SQL Reporting :: Send A Report As Body Of The Mail?

Aug 12, 2010

im using report viewer to display the report in aspx page.

i want to send this report as body of a mail we are sending the mail stmp Clinent.

how to do this?

View 1 Replies

Web Forms :: Email Text Formatting Not Changing When Sending An Email

Jul 18, 2010

I am sending an email for forgot password to the user. i have formatted the body text of Email but when i have checked that email, it is coming without any formatting.

here is the formatting code which i am sending as a string.....

View 7 Replies

Web Forms :: Sending An Email Causes Error - Specified String Not In Email Format

Feb 12, 2010

have code on a web form -- when you hit the button "send emails", it executes this sub which reads an SQL database table and sends emails one by one -- however I get this error above -- anyway to check it and skip to the next email? Some emails in my table have name@test.co.il for example, so it seems this causes this error.

[CODE]

View 1 Replies

C# - MVC Building Email Body?

Aug 13, 2010

I'm coming from web forms and still very new to MVC. I want to create a contact form that simply emails me the contact information,

e.g:

FirstName
LastName
Email
Age
Company

I need to collect about a dozen different fields of information. In web forms it was easy to build the email body just by calling TextBox.Text.What's the best way to build the email body besides having to pass in a long-ass parameter:

[HttpPost]

Public ActionResult Contact(string firstName, string lastName, string Email, int Age, string Company, ...)
{
// ...
}

View 4 Replies

Web Forms :: Sent Webpage As Email Body

Sep 30, 2010

I have a question about E-mail body. I have a button called and when user clicks this button, I want the webpage to be sent to someone as a email body, not as an attachment. (The exact same webpage content) I have been working on this for 3 days and cannot figure it out. The email line is this:

objUtilities.SendEmail(subject, BodyMessage, emailTo, emailFrom);
So something like this: BodyMessage= webpage

View 8 Replies

Web Forms :: How To Put Hyperlink In Body Email

Jan 30, 2011

I want put a hyperlink in body email for changing password. My code is:

First generate URL for navigation URL, I need have 2 querystring in login.aspx page
[Code]....
then
[Code]....
and below code is method of send mail:
[Code]....

But when I send this mail I haven't any hyperlink in body email? Is value of navigation URL is correct?

View 2 Replies

How To Get Values From An Email Body And Into A Database

Feb 22, 2011

What's the easiest method of getting values from an email body and inserting them into a database?

I am able to connect to a POP3 account and read new emails, but I don't know how to 'process' the email content. The email is in plain text format, and the content is like:

test name: 1
another test: No
some other test: 54
final test:

View 4 Replies

Receiving XML From A Text Email Body?

Feb 23, 2011

I was hoping someone could point me in the right direction. I need to set up a way to receive xml from an email. I am to set up an email address that will always receive text emails where the body contains an xml document - not attached, but as the body itself. I know how to parse the xml and all of that once I get it, but I have never done anything like this so I am unsure on how to even set it up.

I assume I have to make some IIS settings that tell the server to execute a page when an email is received to a particular address?

View 3 Replies

Web Forms :: How To Add Hyperlinks In Body Of Email

Jun 19, 2012

how to mail a hyperlinks in a simple mailing service

try {
MailMessage mail = new MailMessage();
mail.To.Add(email);
mail.From = new MailAddress("email_add");
mail.Subject = "New Product Added";

[Code] ....

View 1 Replies

Web Forms :: How To Add Button To Email Body

Jul 17, 2015

My requirement is that, i will display 2 buttons Yes/No in Mail body, if the user clicks on Yes then without redirecting to webpage i need to update value in sql database.How to achieve this?

View 1 Replies

Appending To BODY Element - Error "The Controls Collection Cannot Be Modified"

May 12, 2010

Just before (or during) rendering page I would like to append a piece of code (java script). However when I try to add new LiteralControl via Page.Controls property I get an error: The Controls collection cannot be modified because the control contains code blocks (i.e. <% ... %>).

View 2 Replies

How To Save Data In SQL Server Database And Then Sending The Email Later

Sep 29, 2010

I have a data entry and editing form and in every data entry or update event, I have to send an email to a dynamic list of recipients. I have been sending the email as soon as the user clicks the save or edit buttons but am thinking of first saving the data to the database, and then sending the email later. I want to do this partly to improve the response time of the application as the email sending tends to take a long time than desired.

View 4 Replies

Security :: Sending Form Data Securely By Email?

Jan 17, 2011

I'm building a website for a client on which they want site visitors to be able to fill out a form with the relevant information along with their credit card details, and when they submit the form, the information will be sent to the client in an email. This is an experimental services that they're offering so they're not interested in real time credit card processing yet. If I just zip the collected data up into a password protected zip file, and send that in an email to the client, would it be secure? Or do I have to go further than that to secure the data?

View 1 Replies

Web Forms :: Number Of Characters To Allow For Email Body?

Aug 19, 2010

I have a form that's used to submit emails. I'm not sure what the character limit should be for the body of the email. I'm thinking about setting it at 150. It's used to allow people to inquire about services provided by a small business. Should I allow more? Is this sufficient?

View 2 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved