Is this a valid implementation of thread waiting/pulsing?
As the title says, is this a valid implementation? I'm aware of the `lock` statement's problems, but due to requirements it must be used. Is this code valid?

    
        lock (richTextBox)
                {
                    Monitor.Wait(richTextBox);
                    richTextBox.AppendText("Text");
                    Monitor.PulseAll(richTextBox);
                }

Thanks!
Is this a valid implementation of thread waiting/pulsing?
===

As the title says, is this a valid implementation? I'm aware of the `lock` statement's problems, but due to requirements it must be used. Is this code valid?

    
        lock (richTextBox)
                {
                    Monitor.Wait(richTextBox);
                    richTextBox.AppendText("Text");
                    Monitor.PulseAll(richTextBox);
                }

Thanks!