---
title: "用Preferences,通过xml文件跳转到另一个Activity"
author: "doll"
date: "2010-01-15T15:19:32Z"
tags: []
categories: ["移动开发"]
slug: "preferences-xml-activity"
draft: false
lastmod: "2010-01-15T15:19:32Z"
id: 571140
url: "https://doll.iteye.com/blog/571140"
---

我亲自没有测试过 但是看到发布的人测试过 原文地址：< http://groups.google.com/group/android-developers/browse_thread/thread/8ea1145c3c8b9c0b>

直接上代码

```java

<Preference android:title="Internal activity"
		android:summary="This will launch internal activity">
		<intent android:action="android.intent.action.MAIN"
			android:targetPackage="com.doll.demo" android:targetClass="com.doll.demo.MyInternalActivity"
			android:data="mydata" />
</Preference>

```