I added some code snippets to python script and sent him to client. There is new library, does the the other side to install also package? pip install pywin32
code that added by me to script is;
import win32com.client
xl = win32com.client.Dispatch("Excel.Application") #instantiate excel app
wb = xl.Workbooks.Open(r'C:\Users\jay\Desktop\PythonInOffice\python_run_macro\macro.xlsm')
xl.Application.Run('macro.xlsm!Module1.macro1("Jay")')
wb.Save()
xl.Application.Quit()
From answers': if I write the code below do I need to install sys and subprocess separetely also?
import subprocess
import sys
def install('pywin32'):
subprocess.check_call([sys.executable, "-m", "pip", "install", 'pywin32'])