Silverlight program startup and project migration issues

Source: Internet
Author: User
Tags versions zip zip extension silverlight visual studio visual studio 2010

Kathleen Dollard is a consultant, author, trainer and presenter. She has been Microsoft's most valuable expert since 10. She answered two questions about the hidden errors generated by Silverlight.

Reader: I am migrating a Silverlight project from Visual Studio 2008 to Visual Studio 2010, and the editable and display properties are not found in the compilation. Referring to the System.Data.Annotations.dll (System. Data. Annotation dynamic link library), I did use the declaration correctly. This occurs in a file that is connected to Silverlight and the server and only occurs on the server. Do you know what's going on?

Kathleen: Check the target version of this framework to make sure your target is the correct version. Although Visual Studio 2010 can target earlier versions of the. NET Framework, you may encounter some mismatched compilations. When you migrate from Visual Studio 2008 to Visual Studio 2010, Visual Studio does not change the target framework.

Be cautious about the Visual Studio version and the. NET Framework goals. Although you can use Visual Studio 2010 to target an earlier version of the. NET Framework, opening a project in Visual Studio 2010 changes the project and the assembly file, so this project is in Visual Studio 2008 ( Or earlier versions of this framework) cannot be opened. Since most organizations cannot upgrade all programmers at the same time, this means upgrading on a project-by-item basis, rather than escalating it individually. Use source control because it is easy to migrate a project prematurely to Visual Studio 2010.

Reader: When I start my Silverlight application, I get the error message: "Initialize the error message: illegal or wrong application: Check the list." "Do you know the cause of this error?"

Figure 1:silverlight started with a mysterious error.

Kathleen A: The most common reason for this error is that the startup object is incorrect, possibly because you changed the namespace of the startup object or renamed the Startup object. You set up this startup project in the Silverlight tab or the Project Properties dialog box. Since this Startup object combo box contains this legitimate target, resetting the startup object is one of the easiest ways to bypass any typographical errors that may arise.

A lesser possibility is that the XAP files used for deployment are not made correctly or are corrupted. Although you can query the list and make sure all the files that are marked as compiled are present, deleting and recreating your xap files may also be effective. Since this XAP file is actually a zip file, if you rename a file and have a. zip extension, you can search for the file using a Windows file browser.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.