Computer >> कंप्यूटर ट्यूटोरियल >  >> प्रोग्रामिंग >> C#

C# में Char.ConvertFromUtf32(Int32) विधि

C# में Char.ConvertFromUtf32(Int32) विधि का उपयोग निर्दिष्ट यूनिकोड कोड पॉइंट को UTF-16 एन्कोडेड स्ट्रिंग में बदलने के लिए किया जाता है।

सिंटैक्स

public static string ConvertFromUtf32 (int utf32);

यहां, पैरामीटर utf32 एक 21-बिट यूनिकोड कोड पॉइंट है।

उदाहरण

आइए Char.ConvertFromUtf32(Int32) विधि को लागू करने का एक उदाहरण देखें:

using System; 
public class Demo { 
    public static void Main(){ 
        int utf = 0x0051; 
        string str = Char.ConvertFromUtf32(utf); 
        Console.WriteLine("मान = " + str); 
    } 
}

आउटपुट

मान = Q

उदाहरण

using System; 
public class Demo { 
    public static void Main(){ 
        int utf = 0x0046; 
        string str = Char.ConvertFromUtf32(utf); 
        Console.WriteLine("मान = " + str); 
    } 
}

आउटपुट

मान = F
  1. - C# में Char.ConvertToUtf32(String, Int32) मेथड

    C# में Char.ConvertToUtf32(String, Int32) मेथड का उपयोग एक स्ट्रिंग में निर्दिष्ट स्थिति पर UTF-16 एन्कोडेड वर्ण या सरोगेट जोड़ी के मान को एक यूनिकोड कोड पॉइंट में परिवर्तित करने के लिए किया जाता है। सिंटैक्स निम्नलिखित सिंटैक्स है - public static int ConvertToUtf32 (string str, int index); यहां, s

  1. - C# में Char.ToUpperInvariant(Char) मेथड

    C# में Char.ToUpperInvariant() मेथड का उपयोग एक यूनिकोड वर्ण के मान को उसके अपरकेस समतुल्य में परिवर्तित करने के लिए किया जाता है, जिसमें अपरिवर्तनीय संस्कृति के केसिंग नियमों का उपयोग किया जाता है। सिंटैक्स public static char ToUpperInvariant (char ch); यहां, पैरामीटर ch परिवर्तित किया जाने वाला य

  1. - C# में Char.IsControl(String, Int32) मेथड

    C# में Char.IsControl(String, Int32) मेथड का उपयोग यह दर्शाने के लिए किया जाता है कि किसी निर्दिष्ट स्ट्रिंग में निर्दिष्ट स्थिति पर वर्ण एक नियंत्रण वर्ण के रूप में वर्गीकृत है या नहीं। सिंटैक्स public static bool IsControl (string str, int index); ऊपर, str एक स्ट्रिंग है। index पैरामीटर str में म