콘텐츠로 건너뛰기
메뉴
커뮤니티에 참여하려면 회원 가입을 하시기 바랍니다.
신고된 질문입니다
3 답글
8688 화면

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
2846
3
1월 16
5720
3
12월 15
4042
0
1월 17
4074
0
6월 16
3348