Dialog Resize

Dialog Resize


I am creating a photo alubm and want to display the full size image in
a jquery modal dialog.
The modal dialog opens just fine, but it doesn't resize to show the
full picture. Below is the code I am using. Each image calls the
"OpenFullSized(...)" function. Changing the size manually seems to
work for the width, but no matter ho high i set the height, i get a
scroll bar.
Any ideas?
    <div id="FullSizedPic">
        <img id="FullSizedPicImg" src="" alt="" title="" />
    </div>
<script type="text/javascript">
    $(document).ready(function()
    {
        $('#FullSizedPic').dialog({ buttons: { "Close": function() { $
('#FullSizedPic').dialog("close"); }}, autoOpen: false, modal: true,
resizable: true });
    });
    function OpenFullSized(url, altValue, titleValue)
    {
        var picture = document.getElementById('FullSizedPicImg');
        picture.src = url;
        picture.alt = altValue;
        picture.title = titleValue;
        $("#FullSizedPic").data("width.dialog", picture.width + 30).data
("height.dialog", picture.height + 100);
        $('#FullSizedPic').dialog('option', 'title', titleValue);
        $('#FullSizedPic').dialog("open");
    }
    </script>