AmitDiwan has Published 11365 Articles

DateTime.GetDateTimeFormats() Method in C#

AmitDiwan

AmitDiwan

Updated on 08-Nov-2019 10:34:11

893 Views

The DateTime.GetDateTimeFormats() method in C# is used to convert the value of this instance to all the string representations supported by the standard date and time format specifiers.SyntaxFollowing is the syntax −public string[] GetDateTimeFormats () public string[] GetDateTimeFormats (char ch);Above, ch is a standard date and time format string.ExampleLet us ... Read More

DateTime.FromOADate() Method in C#

AmitDiwan

AmitDiwan

Updated on 08-Nov-2019 07:18:25

462 Views

The DateTime.FromOADate() method in C# is used to return a DateTime equivalent to the specified OLE Automation Date.SyntaxFollowing is the syntax −public static DateTime FromOADate (double val);Above, Val is the OLE Automation Date value.ExampleLet us now see an example to implement the DateTime.FromOADate() method −using System; public class Demo { ... Read More

UInt32 Struct in C#

AmitDiwan

AmitDiwan

Updated on 08-Nov-2019 07:16:41

753 Views

The UInt32 struct represents a 32-bit unsigned integer. The UInt32 value type represents unsigned integers with values ranging from 0 to 4, 294, 967, 295.Let us now see some examples of UInt32 Struct methods −UInt32.CompareTo()The UInt32.CompareTo() method in C# is used to compare the current instance to a specified object ... Read More

UInt16 Struct in C#

AmitDiwan

AmitDiwan

Updated on 08-Nov-2019 07:13:52

357 Views

The UInt16 struct represents a 16-bit unsigned integer. The UInt16 value type represents unsigned integers with values ranging from 0 to 65535.Let us now see some examples of UInt16 Struct methods −UInt16.CompareTo()The UInt16.CompareTo() method in C# is used to compare the current instance to a specified object or UInt16 and ... Read More

Math Class in C#

AmitDiwan

AmitDiwan

Updated on 08-Nov-2019 07:10:02

993 Views

The Match class has static methods and constants for trigonometric, logarithmic and other mathematical functions.The Math class in C# has Math.E and Math.PI fields. Let us see an example of both the fields −Math.EIt is the natural logarithmic base specified by the constant e.SyntaxThe syntax is as follows −public const ... Read More

Uri.GetHashCode() Method in C#

AmitDiwan

AmitDiwan

Updated on 08-Nov-2019 07:07:29

24 Views

The Uri.GetHashCode() method in C# gets the hash code for the URI.SyntaxFollowing is the syntax −public override int GetHashCode ();ExampleLet us now see an example to implement the Uri.GetHashCode() method −using System; public class Demo {    public static void Main(){       string URI1 = "https://www.tutorialspoint.com/index.htm";     ... Read More

Uri.FromHex() Method in C#

AmitDiwan

AmitDiwan

Updated on 08-Nov-2019 07:05:15

37 Views

The Uri.FromHex() method in C# is used to get the decimal value of a hexadecimal digit.SyntaxFollowing is the syntax −public static int FromHex (char digit);Above, the parameter digit is the hexadecimal digit (0-9, a-f, A-F) to convert.ExampleLet us now see an example to implement the Uri.FromHex() method −using System; public ... Read More

Uri.EscapeDataString(String) Method in C#

AmitDiwan

AmitDiwan

Updated on 08-Nov-2019 07:02:07

724 Views

The Uri.EscapeDataString() method in C# converts a string to its escaped representation.SyntaxFollowing is the syntax −public static string EscapeDataString (string str);Above, the string str is the string to escape.ExampleLet us now see an example to implement the Uri.EscapeDataString() method −using System; public class Demo {    public static void Main(){ ... Read More

UInt32.ToString() Method in C# with Examples

AmitDiwan

AmitDiwan

Updated on 08-Nov-2019 07:00:29

2K+ Views

The UInt32.ToString() method in C# is used to convert the numeric value of the current UInt32 instance to its equivalent string representation.SyntaxFollowing is the syntax −public override string ToString();ExampleLet us now see an example to implement the UInt32.ToString() method −using System; public class Demo {    public static void Main(){ ... Read More

UInt32.GetTypeCode() Method in C# with Examples

AmitDiwan

AmitDiwan

Updated on 08-Nov-2019 06:54:17

58 Views

The UInt32.GetTypeCode() method in C# is used to return the TypeCode for value type UInt32.SyntaxFollowing is the syntax −public TypeCode GetTypeCode ();ExampleLet us now see an example to implement the UInt32.GetTypeCode() method −using System; public class Demo {    public static void Main(){       uint val1 = 55; ... Read More

Advertisements