Today I was working with a customer who wanted to show their SSRS 2005 reports in SharePoint. As many of you might be aware, from SP 2 of SQL 2005 there is an option of storing you reports on the SharePoint Server. Very nice, but I havn’t really tried getting that to work with MS CRM 3, so the SSRS I was using ran in normal mode, i.e. not SharePoint integration. However, I did want to show the reports and the reports explorer in SharePoint. For SharePoint v2 there has long existed RSWebparts.cab, which is a web part package consisting of two web parts; report viewer and report explorer.
After a bit of looking I couldn’t find it for SharePoint v3, and found some information saying that the old webparts actually still worked well. So, after the always so tedious work of trying to locate the file, RSWebparts.cab (it cannot be downloaded from the Internet as far as I know) I installed it using stsadm –o installwp -o addwppack -force –filename “C:tempRSWebParts.cab” –globalinstall (use stsadm –help addwppack to see possible syntax), and adding the RSWebparts.dll as a safecontroll (with the correct strong name). I got it to work, just as nicely as it did in SharePoint v2. So, my suggestion to you, if you have the same need, use the old one.
And where can you find the file? It is installed in some impossible path bellow c:program filesSQL Server of a SQL 2000 SP2 (or greater) server. So, get your hands on it, and don’t let go. I don’t think I can publish it here though, due to copyright reasons.
I was reading a bit on the CRM Teams blog and read a posting on the fact that there is an aspx-page that lists all entities that can also show all attributes of the entity. Read the post here or just brows to: http://<yourservername>/sdk/list.aspx.
You learn something new, every day J.
As many of you who work with development in Microsoft CRM know, callouts is a great tool. Lots of different tasks can be left to be handled by callouts and they are even run when offline data is resynced to the main system. However, a common problem when working with PostUpdate callouts is that the code wants to update the object that created the callout, hence executing the calloutcode again, which might result in an endless recursion.
I recently ran into this problem working at a customer of mine, and found a nice generic way of solving it using the thought behind the design pattern object factory or single instance.
I guess you want some code! Well, the basis of this solution is to have a static instance of a collection that keeps track of if a certain key just has been run. I use the collection StringCollection. It is simple, and just what I needed in this case:
static System.Collections.Specialized.StringCollection justtreated;
Then I created a method that is supposed to return false the first, third, fifth… time it is called and true every second, fourth, sixth… time it is called with a certain key.
bool JustDone(string key)
if (justtreated == null)
justtreated = new System.Collections.Specialized.StringCollection();
The method is not very complicated. First off, it makes sure that the static variable has been created. Then it checks if it can find the key string in the string collection. If it can it will remove it and then return true. If it cannot find the key, it will add it to the collection and return false.
Since, this method is working with a static variable that will remain in memory between instantiations of the class, hence the data will remain between PostUpdate calls.
Then in the beginning of the PostUpdate method just call JustDone() with the object key (or some other unique key) and if it is true, just “return”.
I’ve been bad at reading all blogs recently. Full of work and my private time is now mostly filled with my daughter Nora, hence less time to read up on blogs.
We have all (?!) been waiting for the new MS CRM VPC and it has now been released. It can be downloaded from here:
I havn’t downloaded it myself yet, but I will soon.
CRM and SharePoint Consultant
CRM and SharePoint Consultant