I want to initialize a string,datetime dictionary, I want a \"real\" time value for each string. Later I want to insert the strings into drop down list as keys and
string,datetime
Instead of DateTime you should use TimeSpan
DateTime
Dictionary dictionary = new Dictionary(); dictionary.Add("1 hour", new TimeSpan(1, 0, 0)); //1 hour dictionary.Add("2 days", new TimeSpan(2, 0, 0, 0));//2 days