views:

123

answers:

1

Hi,

I'm trying to create a dialog box in my ASP.NET application with an AJAX ActionLink.

The Ajax ActionLink inserts a partial view into a div in the current view.

I've called a function OnComplete (and I've tried OnSuccess, too) that calls the dialog function for JQuery UI, like so:

function() loaddialog {
$("ContainerwithInsertedPartialView").dialog();
}

Nevertheless, it display the dialog. Any ideas as to what I'm doing wrong?

+2  A: 

You have your function definition wrong, for one. You need to use the id selector (prepend a hash) for another.

function loaddialog() {
    $('#ContainerwithInsertedPartialView').dialog();
}
tvanfosson