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

  • Home
  • SEARCH
  • 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 6703815
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T07:12:57+00:00 2026-05-26T07:12:57+00:00

How do i get the numeric value of a unicode character in C#? For

  • 0

How do i get the numeric value of a unicode character in C#?

For example if tamil character அ (U+0B85) given, output should be 2949 (i.e. 0x0B85)

See also

  • C++: How to get decimal value of a unicode character in c++
  • Java: How can I get a Unicode character’s code?

Multi code-point characters

Some characters require multiple code points. In this example, UTF-16, each code unit is still in the Basic Multilingual Plane:

  • enter image description here (i.e. U+0072 U+0327 U+030C)
  • enter image description here (i.e. U+0072 U+0338 U+0327 U+0316 U+0317 U+0300 U+0301 U+0302 U+0308 U+0360)

The larger point being that one “character” can require more than 1 UTF-16 code unit, it can require more than 2 UTF-16 code units, it can require more than 3 UTF-16 code units.

The larger point being that one “character” can require dozens of unicode code points. In UTF-16 in C# that means more than 1 char. One character can require 17 char.

My question was about converting char into a UTF-16 encoding value. Even if an entire string of 17 char only represents one “character”, i still want to know how to convert each UTF-16 unit into a numeric value.

e.g.

String s = "அ";

int i = Unicode(s[0]);

Where Unicode returns the integer value, as defined by the Unicode standard, for the first character of the input expression.

  • 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-26T07:12:58+00:00Added an answer on May 26, 2026 at 7:12 am

    It’s basically the same as Java. If you’ve got it as a char, you can just convert to int implicitly:

    char c = '\u0b85';
    
    // Implicit conversion: char is basically a 16-bit unsigned integer
    int x = c;
    Console.WriteLine(x); // Prints 2949
    

    If you’ve got it as part of a string, just get that single character first:

    string text = GetText();
    int x = text[2]; // Or whatever...
    

    Note that characters not in the basic multilingual plane will be represented as two UTF-16 code units. There is support in .NET for finding the full Unicode code point, but it’s not simple.

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

Sidebar

Related Questions

How do I get a numeric or string value for a javascript object such
How to get the numeric value from the following string using regular expression AD
Is there any easy way to get the hightest numeric value of an associative
Problem: I just want to get and display the index(in numeric value) of an
i want a function or a code to get numeric value from the string
What is the correct protocol to get a date or numeric value out of
Using SQL Server 2005 I want to get only numeric values from the table
I'm trying to format a numeric value always in the format 9 999,99 (notice
How do I truncate output in BASH? For example, if I du file.name how
How to check whether a string contains any numeric value by jquery? I search

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.