How do I save an ASP.NET form as a .txt or .hrml on the slient side? - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

Welcome to the new platform of Programmer's Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use its exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.

How do I save an ASP.NET form as a .txt or .hrml on the slient side?

nakraminakrami Posts: 2Member
Hi,

I would like to know how I can save an ASP.NET form containing a number of controls (textboxes, labels, dropdowns, and etc.) as an .txt or .html format on the client side. I then need this .txt or .html file to be attached to the e-mail and eventually be tasked in Outlook.

I appreciate any input on this.

Thanks a lot.

Comments

  • iwilld0itiwilld0it Posts: 1,134Member
    : Hi,
    :
    : I would like to know how I can save an ASP.NET form containing a number of controls (textboxes, labels, dropdowns, and etc.) as an .txt or .html format on the client side. I then need this .txt or .html file to be attached to the e-mail and eventually be tasked in Outlook.
    :
    : I appreciate any input on this.
    :
    : Thanks a lot.
    :

    You can use the SmtpMail component from the System.Web.Mail namespace. Basically build the HTML you want to attach and save it as an HTML file using StreamReader and StreamWriter from the System.IO namespace. Using SmtpMail you can attach that saved file.

Sign In or Register to comment.