Try this code
<a href="#" class="details-trigger" onclick="ShowDialog()">Show Dialog</a>
function ShowDialog()
{
$('<div>').dialog({
modal: true,
open: function () {
$(this).load("/Controller/PartialView/?AnyParam=" + id);
},
height: 250, width: 400, title: 'My Dialog', buttons: {
"OK":function(){
//whatever
}
},
close: function(){
$(this).html("");
}
});
}