How can I show a dialog box like stackoverflow?
<p>I have the following code on my page:</p>

<pre><code>$('#Report').click(Report);

    function Report() {
        var e = encodeURIComponent,
                arr = [
                "dataSource=" + e($('#DataSource').val()),
                "statusID=" + e($('#StatusID').val())
                ];
        window.location.href = '/Administration/Tests/Report?' + arr.join("&amp;");
        return false;
    }
</code></pre>

<p>When a user clicks on the button with Id=Report then the function is called and it shows a page with report information. </p>

<p>However if the dataSource and statusID are not set then my code ends in an exception. </p>

<p>Is there some way I can check for the value of DataSource not being equal to "00" and StatusID not being equal to "0" and then show a dialog box telling the user these fields should be selected. </p>

<p>Ideally I would like to have something like the dialog box that Stackoverflow uses.</p>
