【发布时间】:2020-05-29 21:15:18
【问题描述】:
我想要解决这个问题----如果我点击 PDF、Doc、PPTX、Docx 文件,那么如何提供多个选项来打开该文件。 如何在 WPS office 等构建应用程序中在手机中打开该文件。
This is my code to show files in listview:
ListView.builder(
scrollDirection: Axis.vertical,
shrinkWrap: true,
itemCount: attachments.length,
itemBuilder: (BuildContext ctxt, int index) {
print (index);
return ListView(
scrollDirection: Axis.vertical,
shrinkWrap: true,
children: <Widget>[
Padding(
padding: const EdgeInsets.all(1.0),
child: ListTile(
leading: CircleAvatar(
child: _getIcon(
attachments[index].split('/').removeLast()),
backgroundColor: Colors.white,
),
subtitle:
Text(attachments[index].split('/').removeLast()),
onTap: (){}
),
),
]);
})
现在点击文件如何在手机 WPS 办公应用中打开该文件。
【问题讨论】:
-
显示一些代码并更好地解释您的问题
-
我已经添加了我的代码