[英]How to set limitations for excel file with xlsx writer
I want to generate an excel using python xlsxwriter module with the header, so that others can fill data in it. 我想使用带有标头的python xlsxwriter模块生成一个excel,以便其他人可以在其中填充数据。 I am able to generate excel but, I want to restrict the user to enter only 5digits in a column.
我能够生成excel,但是我想限制用户在列中仅输入5位数字。 How to achieve this?
如何实现呢? Even I set column width, it is not reflecting.
即使设置了列宽,它也不能反映出来。
You can do this with the Excel Data Validation option in XlsxWriter. 您可以使用XlsxWriter中的Excel数据验证选项来执行此操作。
See the Working with Data Validation section of the docs and this example . 请参阅文档的“使用数据验证”部分和此示例 。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.