跳至內容
選單
此問題已被標幟
1 回覆
3490 瀏覽次數

hi

i want to create a button to do the hotkey "ctrl+p".

the following code in my .xml file:


<button string="Print PDF" name="print_report" type="object" class="oe_highlight" icon="fa-print"/>
and in .py file:
import pyautogui
@api.one
def print_report(self):
return pyautogui.hotkey('ctrl', 'p')
those codes are properly work in microsoft edge and internet explore , but not work in chorome. why?
please help me to find the solution.
thanks

頭像
捨棄
作者 最佳答案


    return pyautogui.hotkey('ctrl', 'shift','p')
It's done.


頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
2
9月 19
3295
1
1月 20
5009
0
11月 16
4320
0
9月 23
1874
0
9月 23
1576