This is a migrated thread and some comments may be shown as answers.

CRM Demo

6 Answers 356 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Jason
Top achievements
Rank 1
Jason asked on 18 Nov 2011, 10:25 PM
I am attempting to rebuild the crm demo from scratch to get a better understanding of how prism is being implimented. When ever I have a module with any region controls in the view  I recieve an
UpdateRegionsException
An exception occurred while trying to create region objects.
    - The most likely causing exception was: 'System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> Microsoft.Practices.Prism.Regions.Behaviors.RegionCreationException: An exception occurred while creating a region with name 'ContactListRegion'.

{Microsoft.Practices.Prism.Regions.Behaviors.DelayedRegionCreationBehavior.CreateRegion(DependencyObject targetElement, String regionName).  ---> Microsoft.Practices.ServiceLocation.ActivationException: Activation error occured while trying to get instance of type AutoPopulateExportedViewsBehavior, key "" ---> System.InvalidOperationException: Sequence contains more than one element
   at System.Linq.Enumerable.Single[TSource](IEnumerable`1 source)

6 Answers, 1 is accepted

Sort by
0
Stanislav
Telerik team
answered on 21 Nov 2011, 09:30 AM
Hello Jason,

At first glance it seems that you have several copies of AutoPopulateExportedViewsBehavior in memory and MEF can’t decide which one to use.

If you have an Infrastructure project with the behavior inside, which you reference among your other projects, make sure you have CopyLocal=false set on the project reference and on Prism & MEF assemblies too.

If you want to use the AutoPopulateExportedViews behavior, check out Prism’s StockTrader Reference Implementation.
They are using a very nice architecture we tried to follow.
You can view it by running the “Desktop & Silverlight - Open RI - StockTrader Reference Implementation.bat” file in Prism’s root folder. Their help describes the views/region registration process too.

Also, check out our LOB Chronicles series, especially posts #7 and #8. Evan has described our approach on views and regions there.

Please contact us if there are any more problems.

All the best,
Stanislav
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Gonzalo
Top achievements
Rank 2
answered on 21 Nov 2011, 08:36 PM
Greetings,

Would it be possible to get the SQL scripts to install the database for the CRM demo. I am getting conflicts because I have the latest version SQL Server 2008 SP2 and the demo comes with database version 661 my instance of SQL supports 662...

Thanks.
0
Stanislav
Telerik team
answered on 22 Nov 2011, 03:32 PM
Hello Gonzalo,

I have attached the generation script.
It will also be available in one of the next CRM source code uploads.

If there are any problems with the database, you can change the script.

Feel free to contact us if you have any more issues.


Greetings,
Stanislav
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

0
Gonzalo
Top achievements
Rank 2
answered on 22 Nov 2011, 06:35 PM
Excellent!

Have a great day!
0
Jason
Top achievements
Rank 1
answered on 23 Nov 2011, 12:26 AM
Thank you, that solved that problem.
0
Mike
Top achievements
Rank 1
answered on 13 Apr 2012, 05:37 PM
Hi,

Were you successful in getting the SQL pieces to work from the sample?  I am attempting to reference the sample CRM during the trial period to see how challenging it will be to create some other dashboards after the trial concludes.

Thanks in advance.
Tags
General Discussions
Asked by
Jason
Top achievements
Rank 1
Answers by
Stanislav
Telerik team
Gonzalo
Top achievements
Rank 2
Jason
Top achievements
Rank 1
Mike
Top achievements
Rank 1
Share this question
or