Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Saving an existing workbook under a new name should default to Python cwd and rel. dirs should be supported #185
Also I confirm the same problem in
Here it is some rough code to reproduce it:
>>> import xlwings as xw, os.path as osp >>> cd D:\Work >>> fpath = r'.\foo-book.xlsx' ## RELATIVE filepath >>> bk = xw.Book() >>> bk.save(fpath); bk.close() >>> osp.isfile(fpath) False >>> xw.Book(fpath) Could not connect to workbook ''.\foo-book.xlsx'' >>> osp.isfile(osp.join(r'C:\Users\user\Documents', fpath)) True >>> fpath = r'D:\Work\foo-book.xlsx' ## ABSOLUTE filepath >>> bk = xw.Book() >>> bk.save(fpath); bk.close() >>> osp.isfile(fpath) True >>> xw.Book(fpath) <Book [foo-book.xlsx]> ''' The same behavior applies when using UNIX-like paths.