
windows7環境下,執行代碼報ValueError: embedded null byte時,在原代碼前面加一行代碼:locale.setlocale(locale.LC_ALL,'en')即可解決
即:
locale.setlocale(locale.LC_ALL,'en')
locale.setlocale(locale.LC_CTYPE,'chinese')
ws["C3"]=time.strftime('%Y年%m月%d日 %H時%M分%S秒',time.localtime())

windows7環境下,執行代碼報ValueError: embedded null byte時,在原代碼前面加一行代碼:locale.setlocale(locale.LC_ALL,'en')即可解決
即:
locale.setlocale(locale.LC_ALL,'en')
locale.setlocale(locale.LC_CTYPE,'chinese')
ws["C3"]=time.strftime('%Y年%m月%d日 %H時%M分%S秒',time.localtime())
本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。