我是XamarinStudio的新手,可以创建Android App。这里有问题:
1什么是Manifest和AndroidManifest。如何创建它们或它是自动创建的?
如何为第一次启动时显示的应用设置默认活动。在Windows Phone中,默认页面称为MainPage.xaml。
当我在项目中添加另一个Activity时,是否必须在Manifest或AndroidManifest中声明它?
由于
在Eclipse中:默认的Activity是setUp到Intent-filter为
intent-filter action android:name="android.intent.action.MAIN" category android:name="android.intent.category.LAUNCHER" intent-filter
如何在XamarinStudio中完成?
答案 0 :(得分:0)
根据Developer.Android.com上的文档
清单提供有关申请的基本信息 Android系统,系统在运行之前必须具备的信息 任何应用程序的代码。
更多信息...... http://developer.android.com/guide/topics/manifest/manifest-intro.html
应用程序的默认活动与您在创建应用程序时配置的名称相同,“activity_main.xml”或个性化名称。
<强> PROJECT_NAME - &GT; RES - &GT;布局 - &gt; activity_main.xml
http://www.mkyong.com/android/how-to-set-default-activity-for-android-application/
答案 1 :(得分:0)
使用Xamarin构建Android应用时,您可以在实际活动中设置主要活动。
当您打开活动的代码文件时,您可以输入以下内容:
[Activity(Label = "MyAppName", MainLauncher = true, Icon = "@drawable/icon", ScreenOrientation = ScreenOrientation.Portrait)]