Create Case page error - Sequence contains no matching element

May 24, 2010 at 9:18 PM

Here are the details

[InvalidOperationException: Sequence contains no matching element]
   System.Linq.Enumerable.First(IEnumerable`1 source, Func`2 predicate) +731197
   Site.Pages.eService.CreateCase.CreateButton_Click(Object sender, EventArgs e) in C:\R5 Builds\Security Testing\Customer-Portal-R2\Website\Pages\eService\CreateCase.aspx.cs:40
   System.Web.UI.WebControls.Button.OnClick(EventArgs e) +111
   System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +110
   System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +10
   System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13
   System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +36
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1565

I read the other article, it mention match the lable name for case subject, can someone explain in details what needs to be matched or how to solve this issue.

Thanks,

Meg

May 25, 2010 at 12:06 AM

The line that is failing is looking up a site setting (a CRM entity) with the name "case/prioritycode" and then finding the option label that corresponds to that.  I suspect that you have customized your case priorities, and the customizations no longer are in-sync with the site setting.  The fix is simple - change the site setting in CRM to a value that matches your CRM deployment.

Shan McArthur
www.shanmcarthur.net

May 25, 2010 at 6:17 AM

This could also be caused by the "default subject" setting. In my case the default subject was set to a non-existing subject in the VPC I was using. When I changes the setting to an existing subject, case was created OK.

Jorulf

May 25, 2010 at 3:02 PM

Thank you very much Shan and Jorulf, that fixed my issue. 

How can I publish more attributes from Case to the portal for view case as well as for the create case?

Thanks,

Meg

 

 

May 25, 2010 at 3:09 PM

The columns in the view cases screen can be managed in CRM by customizing the cases view named "Cases Web View".  If you also want to bring forward more attributes, you will also have to edit the CreateCase.aspx and EditCase.aspx files (and their associated code-behind files).

Shan

Jul 27, 2010 at 4:18 PM

Hi Shan,

I've tried editing the "Cases Web View" and publishing it out, but the added columns don't appear in the Cases grid.  Does this require cache clearing or IISReset for the changes to take?

Jul 27, 2010 at 5:24 PM

Yes. Reset your cache.  You need to reset cache anytime you change anything except data in CRM. 

Todd Shelton

206-383-9512

From: agarcia528 [mailto:notifications@codeplex.com]
Sent: Tuesday, July 27, 2010 8:19 AM
To: Todd Shelton
Subject: Re: Create Case page error - Sequence contains no matching element [customerportal:213680]

From: agarcia528

Hi Shan,

I've tried editing the "Cases Web View" and publishing it out, but the added columns don't appear in the Cases grid. Does this require cache clearing or IISReset for the changes to take?

Read the full discussion online.

To add a post to this discussion, reply to this email (customerportal@discussions.codeplex.com)

To start a new discussion for this project, email customerportal@discussions.codeplex.com

You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe or change your settings on codePlex.com.

Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at codeplex.com