<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.inetium.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Search results matching tag 'messages'</title><link>http://blogs.inetium.com/search/SearchResults.aspx?a=1&amp;o=DateDescending&amp;tag=messages&amp;orTags=0</link><description>Search results matching tag 'messages'</description><dc:language>en-US</dc:language><generator>CommunityServer 2008.5 SP1 (Build: 31106.3070)</generator><item><title>Available Plugin Messages for a Given Entity in CRM 4.0</title><link>http://blogs.inetium.com/blogs/azimmer/archive/2010/02/15/available-plugin-messages-for-a-given-entity-in-crm-4-0.aspx</link><pubDate>Mon, 15 Feb 2010 13:00:00 GMT</pubDate><guid isPermaLink="false">7346ef18-9fb1-4a4e-be41-9add5078176c:28906</guid><dc:creator>azimmer</dc:creator><description>&lt;p&gt;When I get an unusual plugin request from one of our business analysts, the first thing I ask myself is, &amp;quot;Do they have a message I can 

hijack?&amp;quot;&amp;nbsp; &lt;/p&gt;
&lt;p&gt;With the plugin registration tool, you specify your message first and then the second field filters by what entities support the 

message.&amp;nbsp; That isn&amp;#39;t very useful when you want to determine what messages are available for a given entity.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;I found this useful query on eggheadcafe, posted by Ajith of Microsoft.&amp;nbsp; &lt;a target="_blank" title="http://www.eggheadcafe.com/software/aspnet/31684630/plugin-for-closeopen-opp.aspx" href="http://www.eggheadcafe.com/software/aspnet/31684630/plugin-for-closeopen-
opp.aspx"&gt;http://www.eggheadcafe.com/software/aspnet/31684630/plugin-for-closeopen-opp.aspx&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Just specify the entity name run the query...&amp;nbsp; Hook up the event and start debugging...&amp;nbsp; Hopefully the message is what you 

are looking for!&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;select m.name as &amp;#39;Name Of Method&amp;#39;,&lt;br /&gt;CASE m.availability&lt;br /&gt;WHEN &amp;#39;0&amp;#39; THEN &amp;#39;Server&amp;#39;&lt;br /&gt;WHEN &amp;#39;1&amp;#39; THEN &amp;#39;Offline&amp;#39;&lt;br /&gt;WHEN 

&amp;#39;2&amp;#39; THEN &amp;#39;Both&amp;#39;&lt;br /&gt;END&lt;br /&gt;as &amp;#39;MessageAvailability&amp;#39;,&lt;br /&gt;CASE mf.availability&lt;br /&gt;WHEN &amp;#39;0&amp;#39; THEN &amp;#39;Server&amp;#39;&lt;br /&gt;WHEN &amp;#39;1&amp;#39; THEN 

&amp;#39;Offline&amp;#39;&lt;br /&gt;WHEN &amp;#39;2&amp;#39; THEN &amp;#39;Both&amp;#39;&lt;br /&gt;END&lt;br /&gt;as &amp;#39;SupportedDeploymentForEntity&amp;#39;,&lt;br /&gt;e.name as &amp;#39;PrimaryEntityName&amp;#39;,s.name as 

&amp;#39;SecondaryEntityName&amp;#39;&lt;br /&gt;from sdkmessagefilter mf inner join sdkmessage m on m.sdkmessageid =&lt;br /&gt;mf.sdkmessageid&lt;br /&gt;left outer join 

entity e on e.objecttypecode = mf.primaryobjecttypecode&lt;br /&gt;left outer join entity s on s.objecttypecode = mf.secondaryobjecttypecode&lt;br /&gt;where mf.primaryobjecttypecode &amp;lt; 10000&lt;br /&gt;and mf.primaryobjecttypecode &amp;gt;= 0 -- Includes Enity.none&lt;br /&gt;and 

mf.iscustomProcessingstepallowed = 1&lt;br /&gt;&lt;b&gt;and e.name =&amp;#39;lead&amp;#39; &lt;/b&gt;&lt;br /&gt;order by m.name, e.name&lt;/p&gt;
&lt;p&gt;Enjoy!&lt;/p&gt;
&lt;p&gt;-Andrew&lt;/p&gt;</description></item></channel></rss>