sengzhao666

实现代码:

import tkinter as tk
from tkinter import filedialog

def getLocalFile():
    root=tk.Tk()
    root.withdraw()

    filePath=filedialog.askopenfilename()

    print(\'文件路径:\',filePath)
    return filePath

if __name__ == \'__main__\':
    getLocalFile()

 

运行截图:

 

 

 

分类:

技术点:

相关文章:

  • 2021-12-27
  • 2021-04-19
  • 2022-02-07
  • 2022-01-01
  • 2021-12-09
  • 2021-09-12
  • 2021-11-28
  • 2021-12-02
猜你喜欢
  • 2021-12-20
  • 2021-11-28
  • 2021-11-07
  • 2021-11-28
  • 2021-10-27
  • 2021-12-12
相关资源
相似解决方案