I have some code and when it executes, it throws a NullReferenceException, saying: Object reference not set to an instance of an object. What does this mean, and what can I do to fix this error?...
What is the simplest way to update a Label from another thread? I have a Form on thread1, and from that I'm starting another thread (thread2). While thread2 is processing some files I would like to u...
I have some code and when it executes, it throws a IndexOutOfRangeException, saying, Index was outside the bounds of the array. What does this mean, and what can I do about it? Depending on cl...
In .NET System.Object.GetHashCode method is used in a lot of places, throughout the .NET base class libraries. Especially when finding items in a collection fast or to determine equality. Is there a ...
I want to do something like: MyObject myObj = GetMyObj(); // Create and fill a new object MyObject newObj = myObj.Clone(); And then make changes to the new object that are not reflected in the orig...
How can I create an Excel Spreadsheet with C# without requiring Excel to be installed on the machine that's running the code?
Instead of relying on my host to send email, I was thinking of sending the email messages using my Gmail account. The emails are personalized emails to the bands I play on my show. Is it possible to d...
Is there a way to deserialize JSON content into a C# 4 dynamic type? It would be nice to skip creating a bunch of classes in order to use the DataContractJsonSerializer.
Can someone give me the code to encrypt and decrypt a string in C#?
Once my program is installed on a client machine, how do I force my program to run as an administrator on Windows 7?