Passing object to dialog box

Passing object to dialog box

I am using the $.ajax funtionality with the UI dialog box plugin .  I need to pass an object to the dialog box.  I have tried
 
.ajax({
            prompt: 'POST',
            url: '/page.jsp',
            data: {
                objVal: $object      



            },
            success: function(data) { $dialog.html(data);}
});

 
when I do this I get:
Line: 31
Error: Object doesn't support this action
 
According to the script debugger this issue is in the jquery code:
  isEmptyObject:function(j){for(var s in j)return false;return true}
 
 
How can I pass my object to my dialog box without getting an error?