Advertisement
Guest User

Untitled

a guest
Jul 26th, 2016
54
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.48 KB | None | 0 0
  1. Dim existing = sd.getTimesValues(emailid, day, sesh, includeEnquiryOnly)
  2. Dim dictionary As Dictionary(Of String, DaysAndTimes.timedata) = Nothing
  3. Dim sorted As List(Of KeyValuePair(Of String, DaysAndTimes.timedata)) = (From kv In existing Order By kv.Value).ToList()
  4. For Each kv As KeyValuePair(Of String, DaysAndTimes.timedata) In sorted
  5. dictionary.Add(kv.Key, kv.Value)
  6. Next
  7.  
  8. Dim dictionary = existing.OrderBy(Function(y) y.Value).ToDictionary(Function(x) x.Key, Function(y) y.Value)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement