Ajax action link not calling the corresponding method in controller

January 30, 2012 at 2:38 PMMadestro

So I was working on an ASP.NET MVC application and stumbled upon a little situation that was driving me nuts. I had an action link which used a confirmation message box that would allow the user to delete a record. The code was straight forward but for some reason the action would not fire on the controller.

After trying a few things I realized I was using some boiler plate code that provided standard handlers for the events:

new AjaxOptions() { Confirm = "Are you sure you want to delete this record from the system?", UpdateTargetId = "Results", HttpMethod = "POST", LoadingElementId = "LoadingContainer", OnSuccess = "Ajax_OnSuccess", OnFailure = "Ajax_OnFailure", OnBegin = "Ajax_OnBegin", OnComplete = "Ajax_OnComplete" }

(Scroll to the right on the code line, notice the "Ajax_" event handlers)

The issue turned out to be that I had forgotten to include the script file with these functions into my page. Apparently, if you provide method names but do not provide the implementation, it breaks the call to the action.

I hope this saves someone else some time...

Posted in: ASP.NET MVC

Tags:

Expanding the list of databases in SQL Management Studio 2008 takes a long time or loads indefinitely

January 13, 2012 at 1:38 PMMadestro

I was trying to connect to my hosted database with SQL Management Studio 2008 when I ran into an issue. I was able to connect fine using my database credentials but when I attempted to expand the Databases node, Object Explorer just hung trying to load the list of databases. I could run queries and everything, but the database list node would not load.

The issue turned out to be the amount of data being loaded by Object Explorer. Because my provider hosts a lot of databases, Object Explorer was taking an unusually long time loading all the information for every database in the list.

The solution to this issue is:

  • Login to any database server
  • Select the "Databases" node in Object Explorer
  • In the top menu, select "View -> Object Explorer Details"
  • When the "Object Explorer Details" tab opens, right click on any of the headers (.e.g Name, Owner, etc) to get a list of columns to display
  • Uncheck all the columns you don't need. I personally keep only the Name and Owner columns checked
  • Restart SQL Management Studio

Log in to your server again and the databases should be displayed normally.

Here is the link to the original post I found in order to troubleshoot this issue: http://stackoverflow.com/questions/2013923/expanding-list-of-databases-in-sql-server-2008-management-studio-takes-longer-th

Posted in: Databases

Tags:

Finally running my own blog

January 12, 2012 at 10:34 AMMadestro

Well, it had to happen sometime. I finally got my own blog up and running!

Welcome and thanks for stopping by!

I must say, I am impressed with what the BlogEngine.NET guys have done. Their blog engine is very easy to setup. I was up and running in no time so special thanks to them. If you are looking for blog software, please visit their page at http://www.dotnetblogengine.net.

Posted in: Everything else

Tags: