c# - 如何在用户手机中创建文件夹和存储文件
问题描述
我正在使用带有 C# 的 Visual Studio 2019。在我的网站上,我为用户提供了以 pdf 格式下载数据的选项。但我不知道如何在手机中创建一个文件夹并自动下载该文件夹中的 pdf 文件。我已经完成了以下编码来创建 pdf。我正在使用 iText7 创建 pdf。
protected void Button2_Click(object sender, EventArgs e)
{
PdfWriter writer = new PdfWriter("c:\\Appointments.pdf);
PdfDocument pdf = new PdfDocument(writer);
Document document = new Document(pdf, PageSize.A4);
Paragraph header = new Paragraph("Patent Record");
document.Add(header);
Paragraph subheader = new Paragraph("Appointment List");
document.Add(subheader);
document.Close();
}
解决方案
推荐阅读
- kubernetes - 在 Kubernetes 集群上使用 Jmeter GUI 运行 Perf 测试
- google-cloud-platform - GCP Identity Aware Proxy 无法识别我创建的允许访问 ip 范围“35.235.240.0/20”的防火墙规则
- vb.net - 如何使用 Object 类型变量访问类的属性?
- javascript - 在 Rails 6 中运行 easyAutocomplete 时出错 - easyAutocomplete 不是函数
- c++ - Node* p 和 Node * p 有什么区别?
- python - 将范围索引转换为日期时间索引时出错
- linux - bigbluebutton 在 Docker 中是否支持 html5?
- node.js - app.sendFile() 不起作用,而且 __dirname 也不起作用
- java - 我可以在 Java 的类方法中使用类变量吗?
- javascript - 无法在本地环境中从 RollBar 上的缩小形式转换 Angular v9 的 JavaScript 错误堆栈跟踪