PermissionError: [Errno 13] Permission denied: 'Abc.xlsx'
Arshad Noman <[email protected]> Wed, 9 Feb 2022 13:42:45 +0500
| Newsgroups | gmane.comp.python.org.uk |
|---|---|
| Message-ID | <CA+0oV2jvW10yViY6Qhc910rvCF0FFxhqSuTMyt+Y6BwCFx2L4Q@mail.gmail.com> |
--===============9178587359804338834== Content-Type: multipart/alternative; boundary="0000000000001523c605d791d443" --0000000000001523c605d791d443 Content-Type: text/plain; charset="UTF-8" When I enter data using Tkinter form in an Excel file when the excel file is closed there is no error but when I enter data using Tkinter form when the excel is already open following error comes: Exception in Tkinter callback Traceback (most recent call last): File "C:\Users\Dani Brothers\Anaconda3\lib\tkinter\__init__.py", line 1705, in __call__ return self.func(*args) File "D:/Python/Book Bank/New folder/PyCharm/Final/Excel.py", line 61, in SaveBook workbook.save(filename="BookBank.xlsx") File "C:\Users\Dani Brothers\Anaconda3\lib\site-packages\openpyxl\workbook\workbook.py", line 392, in save save_workbook(self, filename) File "C:\Users\Dani Brothers\Anaconda3\lib\site-packages\openpyxl\writer\excel.py", line 291, in save_workbook archive = ZipFile(filename, 'w', ZIP_DEFLATED, allowZip64=True) File "C:\Users\Dani Brothers\Anaconda3\lib\zipfile.py", line 1207, in __init__ self.fp = io.open(file, filemode) PermissionError: [Errno 13] Permission denied: 'Abc.xlsx' What to do to correct this error? I have already searched on google search many times but no solution was found. --0000000000001523c605d791d443 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr"><div class=3D"gmail_quote"><div dir=3D"ltr"><div class=3D"= gmail_quote"><div dir=3D"ltr"><span style=3D"color:rgba(0,0,0,0.87);font-fa= mily:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-size:14px">When I e= nter data using Tkinter form in an Excel file when the excel file is closed= there is no error but when I enter data using Tkinter form when the excel = is already open following error comes:</span><br style=3D"color:rgba(0,0,0,= 0.87);font-family:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-size:1= 4px"><br style=3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDraft,Hel= vetica,Arial,sans-serif;font-size:14px"><br style=3D"color:rgba(0,0,0,0.87)= ;font-family:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-size:14px">= <br style=3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetic= a,Arial,sans-serif;font-size:14px"><span style=3D"color:rgba(0,0,0,0.87);fo= nt-family:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-size:14px">Exc= eption in Tkinter callback</span><br style=3D"color:rgba(0,0,0,0.87);font-f= amily:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-size:14px"><span s= tyle=3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetica,Ari= al,sans-serif;font-size:14px">Traceback (most recent call last):</span><br = style=3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetica,Ar= ial,sans-serif;font-size:14px"><span style=3D"color:rgba(0,0,0,0.87);font-f= amily:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-size:14px">File &q= uot;C:\Users\Dani Brothers\Anaconda3\lib\tkinter\__init__.py", line 17= 05, in __call__</span><br style=3D"color:rgba(0,0,0,0.87);font-family:Robot= o,RobotoDraft,Helvetica,Arial,sans-serif;font-size:14px"><span style=3D"col= or:rgba(0,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetica,Arial,sans-ser= if;font-size:14px">return self.func(*args)</span><br style=3D"color:rgba(0,= 0,0,0.87);font-family:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-si= ze:14px"><span style=3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDra= ft,Helvetica,Arial,sans-serif;font-size:14px">File "D:/Python/Book Ban= k/New folder/PyCharm/Final/Excel.py", line 61, in SaveBook</span><br s= tyle=3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetica,Ari= al,sans-serif;font-size:14px"><span style=3D"color:rgba(0,0,0,0.87);font-fa= mily:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-size:14px">workbook= .save(filename=3D"BookBank.xlsx")</span><br style=3D"color:rgba(0= ,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-s= ize:14px"><span style=3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDr= aft,Helvetica,Arial,sans-serif;font-size:14px">File "C:\Users\Dani Bro= thers\Anaconda3\lib\site-packages\openpyxl\workbook\workbook.py", line= 392, in save</span><br style=3D"color:rgba(0,0,0,0.87);font-family:Roboto,= RobotoDraft,Helvetica,Arial,sans-serif;font-size:14px"><span style=3D"color= :rgba(0,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetica,Arial,sans-serif= ;font-size:14px">save_workbook(self, filename)</span><br style=3D"color:rgb= a(0,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;fon= t-size:14px"><span style=3D"color:rgba(0,0,0,0.87);font-family:Roboto,Robot= oDraft,Helvetica,Arial,sans-serif;font-size:14px">File "C:\Users\Dani = Brothers\Anaconda3\lib\site-packages\openpyxl\writer\excel.py", line 2= 91, in save_workbook</span><br style=3D"color:rgba(0,0,0,0.87);font-family:= Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-size:14px"><span style= =3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetica,Arial,s= ans-serif;font-size:14px">archive =3D ZipFile(filename, 'w', ZIP_DE= FLATED, allowZip64=3DTrue)</span><br style=3D"color:rgba(0,0,0,0.87);font-f= amily:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-size:14px"><span s= tyle=3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetica,Ari= al,sans-serif;font-size:14px">File "C:\Users\Dani Brothers\Anaconda3\l= ib\zipfile.py", line 1207, in __init__</span><br style=3D"color:rgba(0= ,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-s= ize:14px"><span style=3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDr= aft,Helvetica,Arial,sans-serif;font-size:14px">self.fp =3D io.open(file, fi= lemode)</span><br style=3D"color:rgba(0,0,0,0.87);font-family:Roboto,Roboto= Draft,Helvetica,Arial,sans-serif;font-size:14px"><span style=3D"color:rgba(= 0,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-= size:14px">PermissionError: [Errno 13] Permission denied: 'Abc.xlsx'= ;</span><br style=3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDraft,= Helvetica,Arial,sans-serif;font-size:14px"><br style=3D"color:rgba(0,0,0,0.= 87);font-family:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-size:14p= x"><br style=3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDraft,Helve= tica,Arial,sans-serif;font-size:14px"><br style=3D"color:rgba(0,0,0,0.87);f= ont-family:Roboto,RobotoDraft,Helvetica,Arial,sans-serif;font-size:14px"><s= pan style=3D"color:rgba(0,0,0,0.87);font-family:Roboto,RobotoDraft,Helvetic= a,Arial,sans-serif;font-size:14px">What to do to correct this error? I have= already searched on google search many times but no solution was found.</s= pan><br></div> </div></div> </div></div> --0000000000001523c605d791d443-- --===============9178587359804338834== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ python-uk mailing list [email protected] https://mail.python.org/mailman/listinfo/python-uk --===============9178587359804338834==--