Click here to Skip to main content
15,891,657 members

Comments by Richard Deeming (Top 200 by date)

Richard Deeming yesterday View    
Aside from wrapping the update in a BeginInit/EndInit block, that code looks like it should work.
this.Resources.BeginInit();
try
{
    this.Resources.MergedDictionaries.Clear();
    this.Resources.MergedDictionaries.Add(resX);
}
finally
{
    this.Resources.EndInit();
}

So what's the problem?
Richard Deeming yesterday View    
That's the thing about "fastest" code - it tends to use more CPU.

Based on your description, you don't want the "fastest" code; you want the "most optimized" code.

But honestly, inserting one million already-sorted integers into a map is not something you're likely to be doing in a real-world application. So it's not much use as a test to compare different map implementations.
Richard Deeming yesterday View    
The error means you have multiple actions which match the request you're making.

But since you've only shown one action, haven't shown the request, and have truncated the error message, nobody can help you.
Richard Deeming 2 days ago View    
As already suggested multiple times when this question was asked over eleven years ago! And based on the comments, it didn't work.

Stick to answering new questions unless you have read all of the existing solutions and confirmed that you are adding something new to the discussion.
Richard Deeming 3 days ago View    
Step 1: Work out what your requirements are.
Step 2: Learn about the algorithm, and decide whether it is appropriate for the problem you are trying to solve.
Step 3: Write some code.

Nobody here is going to do your homework for you. If you genuinely don't know where to start, then talk to your teacher.