Thursday, February 9, 2012

Chart control and Loadbalancer problems

Some third party tools are using the Chart control to create charts on a loadbalanced environment. This can sometimes cause problems, especially if no stickyness is activated on the loadbalanced server. So the charts are created on the memory or on a local drive of the web frontend server by the first request. If the client wants to request the image by a second request and the loadbalancer routes to another server, than the client will never see an image or perhaps sometimes if the loadbalanced routes the client to the server which created the image. So the best method is to activate stickyness so the request goes to the same server.

This configuration can cause also problems. I would recommend you to talk about the good and odds with your network guru.


View Item Link on a SharePoint content query webpart

In standard the link in the content query webpart links directly to the view form of the selected list. If you want to open the link in the dialog framework popup just add the following click event to the link element in the xsl template of your itemstyle.xsl

<a onclick="OpenPopUpPage(this.href, RefreshPage);return false;" href="{$SafeLinkUrl}" title="{@LinkToolTip}"> Some Link Text</a>

You can leave out the second argument, but if you set it to "RefreshPage" function, the page is refreshed if someone has edited the item.

Of course, you can use this function everywhere and not only in the content query webpart if you have the link to the list item in the href attribute.