Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6911907
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T09:01:04+00:00 2026-05-27T09:01:04+00:00

My URL length is capped at 2084 characters and I have forms that need

  • 0

My URL length is capped at 2084 characters and I have forms that need to have essay’s emailed. I am not using MVC, not sure if that matters. Forms are set to POST data, runat=server. I just want the code behind the main page to load and send an email, I don’t need all the variables passed in the URL. Is this possible or does ASP.net just fill up the URL with VIEWSTATE data? If so, how can I send an email with this data without it going in the url?

Oh I also edited the web.config to allow a larger maxQueryStringLength but from what I am reading older browsers don’t really support that anyway.

<form id="infoForm" runat="server" name="contactForm" method="POST" action="#">
  <!--Other form stuff here-->
         <asp:Button class="button" id="submitButton" Text="Submit" runat="server"
         onclick="submitButton_Click" />
</form>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T09:01:05+00:00Added an answer on May 27, 2026 at 9:01 am

    If you are sending an email you don’t need to send the data via the URL. You just send an e-mail using System.Net.Mail and your form data goes into the e-mail.

    Code sample below:

    protected void Btn_SendMail_Click(object sender, EventArgs e)
    {
        MailMessage mailObj = new MailMessage(
            txtFrom.Text, txtTo.Text, txtSubject.Text, txtBody.Text);
    
        SmtpClient SMTPServer = new SmtpClient("localhost");
    
        try
        {
           SMTPServer.Send(mailObj);
        }
        catch (Exception ex)
        { 
            Label1.Text = ex.ToString();
        }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Browsers have limitation on the length of the URLs. IE has limitation that Url
I think the URL length can only be 2000 or so characters long. Otherwise,
I have a fairly simple MVC view that allows for dynamic text input that
Sending request with URL length ~ 4950 characters. Getting the following XMLHTTPRequest.ResponseText: ERROR The
I have written a CGI script that creates an image dynamically using GET data.
I want to get content-length from a URL that it sends me this header:
What is the maximum length of a URL for each browser? Is a maximum
I have to pass a string (input) in GET parameter of a URL, but
i am trying to remove default.aspx from any request that might have it. protected
What is the maximum URL length you can pass to the Wininet function, HttpOpenRequest?

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.