跳至内容
菜单
此问题已终结
3 回复
8675 查看

I have a module in which i can choose a product. Now i want to get that product and generate a txt file with the product information by clicking a button. Is it possible?

形象
丢弃
最佳答案

Yes, create a button and in the function just create the text file like

file = open("newfile.txt", "w")
file.write("hello world in the new file")
file.write("and another line")
file.close()

 then just add all you need.


Kind Regards.

形象
丢弃
编写者 最佳答案

Gustavo, i try your answer, and odoo  tells me that: 

creafich() takes at least 4 arguments (1 given)

形象
丢弃
最佳答案

Hi, hope you it help
https://www.odoo.com/es_ES/forum/ayuda-1/question/not-able-to-create-simple-txt-report-in-odoo-101033#answer-101052

形象
丢弃
相关帖文 回复 查看 活动
0
9月 16
2832
3
1月 16
5715
3
12月 15
4015
0
1月 17
4066
0
6月 16
3342