Hello,
I have a program, that save all xlsx files in xls format. But there is always a pop up that checks the compatibility. How can I skip this pop up with python? I tried to extract it with wb.DisplayAlerts = False and wb.DoNotPromptForConvert = False, but the pop up is still activated.
HEre is the code:
I have a program, that save all xlsx files in xls format. But there is always a pop up that checks the compatibility. How can I skip this pop up with python? I tried to extract it with wb.DisplayAlerts = False and wb.DoNotPromptForConvert = False, but the pop up is still activated.
HEre is the code:
import glob from win32com.client import Dispatch for file in glob.glob('C:\Users\iiii\Desktop\python\files\*.xlsx'): xl = Dispatch('Excel.Application') wb = xl.Workbooks.Add(file) wb.SaveAs(file[:-1], FileFormat=56) xl.Quit()