The thing is users expect to see an instant response to user interface
actions. What happens if the ajax request takes 3 seconds to
complete? There will be a 3 second delay between the user clickig a
control and the user seeing a dialog. Some studies I've read say that
any user interface latency of over 200ms or so is detrimental to the
user experience. If you open the dialog first and then kick the AJAX
operation off then at least the user gets confirmation quickly that
the application has registered his mouse click and has started to do
something about it. If the AJAX request fails you can display that as
a message in the open dialog instead.
There's a slideshow by the guys who developed Plaxo floating around
(
http://yuiblog.com/blog/2007/08/29/video-smarr/ http://video.yahoo.com/watch/1041101) that talks about, among other things, the importance of having a
user interface show to a user that something is happening in response
to his actions as quickly as humanly possible, even if all that is is
a dialog saying "Working" or something.