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

Dialog: Specified cast is not valid on entering report designer

8 Answers 189 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Jafin
Top achievements
Rank 2
Jafin asked on 22 May 2007, 02:57 AM
I've just begun using Reporting as of today.  So far two issues have croppped up.
1. duplicate namespace errors with Reporting project that also is using Telerik Charts, which I saw in a forum post will be fixed in the next version of reporting.

&

2.  After creating a new report, I go to the designer screen and get a "Microsoft Visual Studio" X Specified cast is not valid. prompt.  Everything compiles ok, this is before I do anything to the form.

My environment is VS2005 SP1 running under W2003 SP1.  I've cleaned the project and restarted VS but I still get the prompt.  Any clues on this one?

Thanks,
J.

8 Answers, 1 is accepted

Sort by
0
Rossen Hristov
Telerik team
answered on 22 May 2007, 04:43 PM
Hello Jafin,

We are currently working on the Chart issue and we hope to fix it for Service Pack 1, due before the end of the month.

Have you had any prior versions of Telerik Reporting installed before installing version 1.0? Sometimes, if old assemblies are left, there is a discrepancy between versions.

Can you send us a screenshot of the failure to support@telerik.com? Also, what is your language of development -- VB or CS? What type of Visual Studio project do you put the Report in? Any other info that you might think of will be of great value.
 

Best wishes,
Rossen
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Jafin
Top achievements
Rank 2
answered on 23 May 2007, 01:33 AM
Hi Telerik,

I don't know if this is exactly related to the issue I am havving with the "Specified cast is not valid" dialog or this could be just an introduced error due to code behind. 

But in one project I now am receiving the error on the designer:
The service Telerik.Reporting.Design.Controls.RulerService already exists in the service container. Parameter name: serviceType.

I can't edit the report in the designer any longer.  I have cleaned and rebuilt the project but the error has not gone.  The report works fine in the browser.


0
Jafin
Top achievements
Rank 2
answered on 23 May 2007, 01:42 AM
My error. Something must of been missing/corrupt in the .resx file. Deleted it and the Ruler error has gone. (The specified cast is not valid issue remains).


0
Rossen Hristov
Telerik team
answered on 25 May 2007, 10:48 AM
Hello Jafin,

Can you please answer the questions that we asked in the previous post and send us a screen-shot of the failure, as well as the complete stack trace, so that we can see where this exception is thrown from.

Regards,
Rossen
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Jafin
Top achievements
Rank 2
answered on 28 May 2007, 02:08 AM
Dear Telerik,
I did send an email to support@telerik.com on 23/5/07 at 9:30am GMT+10 providing all the details of the error. (except stack exception, as one is not given).   I will resend the email again today.  Actually I'll create a fault for you.

Regards,
Jason

0
Chavdar
Telerik team
answered on 28 May 2007, 10:03 AM
Thanks for sending the files, Jafin. We'll continue helping from the support ticket.

Greetings,
Chavdar
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Ryan Schneider
Top achievements
Rank 1
answered on 02 Jul 2007, 02:42 PM
I have also been getting the "Microsoft Visual Studio" dialog box with the message of "Specified cast is not valid".  This occurs when clicking on any Telerik report .cs .  It also occurs on the first click of an .aspx web page.

Any resolution on this problem?
0
Svetoslav
Telerik team
answered on 03 Jul 2007, 12:54 PM
Hello Ryan,

There is a known issue with the Visual Studio 2005 that fails to reload some assemblies from its cache. As a result, .NET Framework finds one type loaded twice (from only one assembly, but with two different temporary names that are actually 2 different assemblies in the VS cache) and it fails to cast from one type to the other even if this is the same type. The only possible solution to this is to restart the Visual Studio. There are several articles on the Internet explaining this problem.

You can also verify that you're using the correct version of the Telerik Reporting assemblies as described in this KB article: http://www.telerik.com/support/kb/article/b454K-mce-b454T-cge-b454c-cge.aspx .

Best wishes,
Svetoslav
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
General Discussions
Asked by
Jafin
Top achievements
Rank 2
Answers by
Rossen Hristov
Telerik team
Jafin
Top achievements
Rank 2
Chavdar
Telerik team
Ryan Schneider
Top achievements
Rank 1
Svetoslav
Telerik team
Share this question
or