{"id":115,"date":"2011-01-17T11:19:00","date_gmt":"2011-01-17T05:49:00","guid":{"rendered":"https:\/\/www.inogic.com\/blog\/?p=115"},"modified":"2011-01-17T11:19:00","modified_gmt":"2011-01-17T05:49:00","slug":"use-tracing-in-crm-2011-plugins","status":"publish","type":"post","link":"https:\/\/www.inogic.com\/blog\/2011\/01\/use-tracing-in-crm-2011-plugins\/","title":{"rendered":"Use Tracing in CRM 2011 Plugins"},"content":{"rendered":"<p>CRM SDK provides way for you to include the debug details about your plug-in in case you need to trace the plug-in execution. For this you will have to initialize the \u201cITracingService\u201d. The service provides way to trace the details and display it whenever plug-in fails and throws an exception. <\/p>\n<p>\/\/Initialize the service<br \/>ITracingService tracingService = (ITracingService)serviceProvider.GetService(typeof(ITracingService));<\/p>\n<p>Once initialized, you just need to add the logical and meaningful details as per your logic using below code,<br \/>tracingService.Trace(yourMessage);<\/p>\n<p>Shown below is the example of message shown to the user when plug-in fails and throws exception. <\/p>\n<p><a href=\"http:\/\/1.bp.blogspot.com\/_pMlyDuF-ngc\/TTQm4gc8wYI\/AAAAAAAAApY\/4a6PDftWVTI\/s1600\/1.png\"><img decoding=\"async\" src=\"http:\/\/1.bp.blogspot.com\/_pMlyDuF-ngc\/TTQm4gc8wYI\/AAAAAAAAApY\/4a6PDftWVTI\/s400\/1.png\" border=\"0\" alt=\"\"><\/a><br \/>Hope this helps you how to use Tracing in CRM 2011 plugins!<\/p>\n","protected":false},"excerpt":{"rendered":"<p>CRM SDK provides way for you to include the debug details about your plug-in in case you need to trace the plug-in execution. For this you will have to initialize the \u201cITracingService\u201d. The service provides way to trace the details and display it whenever plug-in fails and throws an exception. \/\/Initialize the serviceITracingService tracingService =\u2026 <span class=\"read-more\"><a href=\"https:\/\/www.inogic.com\/blog\/2011\/01\/use-tracing-in-crm-2011-plugins\/\">Read More &raquo;<\/a><\/span><\/p>\n","protected":false},"author":13,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[20,21,22,24,42],"tags":[1330,1719,1720],"class_list":["post-115","post","type-post","status-publish","format-standard","hentry","category-dynamics-crm-2011","category-dynamics-crm-2013","category-dynamics-crm-2015","category-dynamics-crm-2016","category-plugin","tag-plugins","tag-trace","tag-tracing"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.inogic.com\/blog\/wp-json\/wp\/v2\/posts\/115","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.inogic.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.inogic.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.inogic.com\/blog\/wp-json\/wp\/v2\/users\/13"}],"replies":[{"embeddable":true,"href":"https:\/\/www.inogic.com\/blog\/wp-json\/wp\/v2\/comments?post=115"}],"version-history":[{"count":0,"href":"https:\/\/www.inogic.com\/blog\/wp-json\/wp\/v2\/posts\/115\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.inogic.com\/blog\/wp-json\/wp\/v2\/media?parent=115"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.inogic.com\/blog\/wp-json\/wp\/v2\/categories?post=115"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.inogic.com\/blog\/wp-json\/wp\/v2\/tags?post=115"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}