27. januar 2009 21:51
lea
URL Addressable Queue Views in CRM 4.0
I got the brilliant idea of displaying multiple queues today, and boldly stated it could be done easily with SharePoint and URL addressable views.
Well, I was wrong, although the solution is quite simple.
CRM Queues does not support URL addressing as is, so I had to create something.
After poking around Microsoft.Crm.Web.dll a bit using Reflector, I found that the queue id of your personal queue is set during OnPreRender.
So I made a copy of the /workplaces/home_workplace.aspx file calling it home_workplace_parameter.aspx, and inserted the following after the last <%@ Import %> statement:
<script runat="server" language="C#">
protected override void Render( HtmlTextWriter writer )
{
this.crmGrid.Parameters.Set("qid", Request.QueryString["qid"]);
base.Render(writer);
}
</script>
I really hoped it would work, but it turns out CRM 4.0 validates querystring parameters. That can be remedied by adding a DWORD to the registry:
http://www.eggheadcafe.com/software/aspnet/31131911/crm-parameter-filter--in.aspx
(Add at HKEY_Local_Machine\Software\Microsoft\MSCRM - DWORD DisableParameterFilter = 1)
Now I can go to http://server/organization/workplace/home_workplace_parameter.aspx?qid={xxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx}
There are some script problems and other stuff I'd like to fix, but for now this works good enough. :)
Filed under: Microsoft CRM