Windows Phone 7 development on the 31st day-22nd: application? Or a game?

Source: Internet
Author: User
Tags visual studio 2010

This article is the 22nd day of the "Windows Phone 7 development on the 31st day" series.

Yesterday, I sent a very long article about Silverlight Toolkit for Windows Phone. Today, it will be shorter, but more precious. I will discuss very subtle but important settings in your application settings: type (Genre ).

If you have created a default Windows Phone application (or a default XNA application) and deployed it to the simulator, you may find that it appears in the Application List (that is, the list that appears when you click the arrow in the upper right corner of the Start interface ).

If you have used a real WP7 device, you may find that all the Games appear in the game Hub. There is a simple way to do this, but when you operate on the simulator, your application seems to be "gone. Remember that you can only do this when the program is indeed a game. If you do not tell the truth, the App Hub may reject the request.

Do you still remember 1st?

In this series of 1st, I explained every file in a Silverlight for Windows Phone application. To make some small changes, we need to open the WMAppManifest. xml document. You can find it in solution manager of Visual Studio 2010. It is in the property folder.

In this file, you can find a large amount of metadata about the application. Such as the application icon, application name, and default page to be loaded.

In addition, changing the NavigationPage attribute of DefaultTask is a way to make manual UI testing more convenient. Change the Page name in that node, and your application will load another page. The following is an example:

<Tasks>
<DefaultTask Name = "_ default" NavigationPage = "ProductPage. xaml? Id = 42 "/>
</Tasks>

Now, let's get back to our hand ...... Let our applications appear in the game center, not like other applications on the phone. To do this, we need to modify the Genre attribute of the App node. The following is the default format (I slightly adjusted the Genre order ):

Code <App xmlns = "" Genre = "apps. normal "ProductID =" {partition} "Title =" Day22_AppsVsGames "RuntimeType =" Silverlight "Version =" 1.0.0.0 "Author =" Jeff Blankenburg "Description =" An amazing demo on how to change your app's location. "Publisher =" Blankensoft ">

You can see that the default value of Genre is "apps. normal ". Change it to "apps. games" and then you will see that your program disappears from the simulator (it does not actually disappear, but you cannot see the game center in the simulator ). The following is an example of my modification:

Code <App xmlns = "" Genre = "apps. games "ProductID =" {tags} "Title =" Day22_AppsVsGames "RuntimeType =" Silverlight "Version =" 1.0.0.0 "Author =" Jeff Blankenburg "Description =" An amazing demo on how to change your app's location. "Publisher =" Blankensoft ">

If you have the opportunity to deploy your program to a real device, you will see your game in the game center. In the United States, this means you can try it in November 8. If you are in New Zealand, you can now get a real machine.

If you want to do this, make sure that you have registered the App Hub. Your code can be put on your mobile phone only after you have registered a developer account.

Download Sample Code

This example has no more content than the content I wrote above, but you can download it.

Address: http://www.jeffblankenburg.com/post/31-Days-of-Windows-Phone-7c-Day-22-Apps-vs-Games.aspx

If you like my article, click "recommendation". Thank you!

 

Related Article

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.