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 960359
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T01:10:14+00:00 2026-05-16T01:10:14+00:00

Can someone please tell me how to do this in C#? Convert from Quoted

  • 0

Can someone please tell me how to do this in C#?

Convert from Quoted Printable to binary, and then use UTF-8 encoding to decode that binary to text.

Here is example of text I need quoted:

“Commentaires: Je suis abonn=C3=A9 =C3=A0 la livraison =C3=A0 domicile depuis longtemps.”

  • 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-16T01:10:15+00:00Added an answer on May 16, 2026 at 1:10 am

    OK, so your question is basically two questions in one. First, you need to be able to decode quoted-printable. I’m assuming that you have the encoded text as a string. You’ll have to run through this string with a while-loop, like below. I’ve deliberately left out the part where you turn the two hex characters into a byte; I’m sure you can figure this out for yourself 🙂

    var i = 0;
    var output = new List<byte>();
    while (i < input.Length)
    {
        if (input[i] == '=' && input[i+1] == '\r' && input[i+2] == '\n')
        {
            // skip this
            i += 3;
        }
        else if (input[i] == '=')
        {
            byte b = (construct the byte from the characters input[i+1] and input[i+2]);
            output.Add(b);
            i += 3;
        }
        else
        {
            output.Add((byte)input[i]);
            i++;
        }
    }
    

    At the end of this, output contains the raw bytes. Now all you need to do is decode it using UTF8:

    var outputString = Encoding.UTF8.GetString(output.ToArray());
    

    If you have any questions, please ask in a comment. And remember: don’t copy and use code that you don’t understand 🙂

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Can someone please tell me how to convert this to razor view syntax? <%=
Can someone please tell me where is the error in this code?, I use
Can someone please tell me what this means: 07-04 09:54:38.048: I/DetailActivity(15496): Title that is
Can someone please tell me why this doesn't work? I'm trying to show and
Can someone please tell me whats wrong with this code. I'm not getting complete
Can someone please tell me what's wrong with this sp. The logic seems to
I can't seem to get this text to align vertically. Can someone please tell
Can someone please tell me why this won't work? NSAppleScript* playPause = [[NSAppleScript alloc]
Hi can someone please tell me why this code is incorrect? I'm trying to
Can someone please tell me how can I easily display every record from sqllite

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.