<p>When you lock an object is that object locked throughout the whole application?</p>

<p>For Example, this snippet from C# 3.0 in a Nutshell Section 19.6.1 "Thread Safety and .NET Framework Types":</p>

<pre><code>static void AddItems(  )
  {
    for (int i = 0; i &lt; 100; i++)
      lock (list)
        list.Add ("Item " + list.Count);

    string[] items;
    lock (list) items = list.ToArray(  );
    foreach (string s in items) Console.WriteLine (s);
  }
</code></pre>

<p>Does the first lock:</p>

<pre><code>lock (list)
        list.Add ("Item " + list.Count);
</code></pre>

<p>prevent another thread from accessing:</p>

<pre><code>lock (list) items = list.ToArray(  );
</code></pre>

<p>or can both be executed at the same time?</p>

<p>And does the CLR automatically make your static methods thread safe? Or is that up to the developer?</p>

<p>Thanks,
John</p>

The CLR doesn't automatically make static methods thread-safe; you must do it yourself.
lock(list) uses that object as a lock, so if a different thread reaches another point with lock(list) (with the same 'list' object), the other thread will block until the first thread releases the lock.
To be clear, lock(foo) doesn't "lock the foo object", rather it acquires the lock associated with the foo object so that the critical section (the statement in the construct "lock(o) stmt") runs only when the current thread has acquired the lock.