I believe, I don’t have to write anything
more, instead redirect you to the below fantastic blog which explains the same in detail
.Wednesday, October 26, 2016
Wednesday, September 28, 2016
How to Cast int to enum and back in C#?
How to Cast int to enum and back in C#
To cast an int to enum just do the bellow
MyEnum foo = (MyEnum)myInt;
To cast to enum from a string value do the below
MyEnum foo = (MyEnum) Enum.Parse(typeof(MyEnum), myString)
Tuesday, September 27, 2016
How do I convert byte[] to stream in C#?
The easiest way to convert a byte array to a stream is using the MemoryStream class:
Stream stream = new MemoryStream(byteArray);
Tuesday, August 23, 2016
How to use the CloudConfigurationManager to automatically switch app settings
Here is a good article which tell how
Thursday, June 30, 2016
How to ignore certificate errors while debugging...
While debugging we
use to come across certificate errors when talking to other sites. One of the solution to ignore these certificate errors while debugging is to add the
below code as first statement in Program.cs
ServicePointManager.ServerCertificateValidationCallback += (sender, cert,
chain, sslPolicyErrors) => true;
Monday, June 6, 2016
Implementing self-service portal to reset/unlock user accounts and passwords for your organizations Active Directory
You can find how to accomplish the same here
Tuesday, January 12, 2016
The timestamp syntax is deprecated, use rowversion instead
The timestamp syntax is deprecated. This feature will be removed in a future version of Microsoft SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.
Have a look here https://msdn.microsoft.com/en-us/library/ms182776.aspx
Have a look here https://msdn.microsoft.com/en-us/library/ms182776.aspx
Subscribe to:
Posts (Atom)