I need to improve a function that selects all text in a table
<p>I have this function which selects all text in an element (table in this case)</p>

<pre><code>function SelectText(element) {

    var text = document.getElementById(element);
        var range = document.body.createTextRange();
        range.moveToElementText(text);

        range.select(); 
}
</code></pre>

<p>I need help making it do the following</p>

<ol>
<li>Ignore some words that I specify (ie. not select them)</li>
<li>Automatically put the selected text in clipboard</li>
</ol>
