let textToShare = “Swift is awesome!  Check out this website about it!”
        
        if let myWebsite = NSURL(string: “http://www.zhaisoft.com/”)
        {
            let objectsToShare = [textToShare, myWebsite]
            let activityVC = UIActivityViewController(activityItems: objectsToShare, applicationActivities: nil)
            
            self.presentViewController(activityVC, animated: true, completion: nil)
        }
添加如何中文
要在项目设置->Info里面的Loacalizations一栏里面添加chinese语言。这时项目文件夹里面会出现zh-Hans.lproj和里面的InfoPlist.strings。
InfoPlist.strings留空就行。只要zh-Hans.lproj和InfoPlist.strings存在,UIActivityViewController就会是中文的。