locked
RetrieveMultiple-Opportunity CRM 2011 RRS feed

  • Question

  • I have a date field in Opportunity entity and one text field. I want text fields to be updated as (Today-Date Field) to show gap between those two dates. I want that to be updated automatically whenever user go to any of the views like "My Opportunities", "Open Opportunties" etc.

    I am planning tyo write a plug-in on Retrieve Multiple of Opportunity entity to update this field. Please let me know if this is right approach? Is there any better approach to do this?

    Thanks

    Monday, May 27, 2013 6:21 AM

Answers

  • I think a better approach rather than a plugin is to use a custom report. Create your report in CRM with every customization you want. Then export it and add a column to the rdl file in Visual Studio. In this column capture date now and calculate the difference between the date and today. The advantage of this approach is that it does not decrease the performance of the system. If you write a plugin on RetrieveMultuple of the opportunity, then on every click it should hit the plugin and could result in performance issues.


    My Weblog | My Website

    Monday, May 27, 2013 7:10 AM
    Moderator
  • So, you could use a JavaScript on the load of form or change of the date field to calculate difference. To view all data you could use the report. Actually using retrievemultiple  is not a good idea.


    My Weblog | My Website

    Monday, May 27, 2013 7:31 AM
    Moderator

All replies

  • I think a better approach rather than a plugin is to use a custom report. Create your report in CRM with every customization you want. Then export it and add a column to the rdl file in Visual Studio. In this column capture date now and calculate the difference between the date and today. The advantage of this approach is that it does not decrease the performance of the system. If you write a plugin on RetrieveMultuple of the opportunity, then on every click it should hit the plugin and could result in performance issues.


    My Weblog | My Website

    Monday, May 27, 2013 7:10 AM
    Moderator
  • Thanks for your reply. I want to do this on CRM records, so when they open CRM, they should see that field updated.
    Monday, May 27, 2013 7:22 AM
  • So, you could use a JavaScript on the load of form or change of the date field to calculate difference. To view all data you could use the report. Actually using retrievemultiple  is not a good idea.


    My Weblog | My Website

    Monday, May 27, 2013 7:31 AM
    Moderator