robodk.py 文件源码

python
阅读 31 收藏 0 点赞 0 评论 0

项目:robodk_postprocessors 作者: ros-industrial 项目源码 文件源码
def getSaveFile(strdir='C:\\', strfile = 'file.txt', strtitle='Save file as ...'):
    """Pop up a file dialog window to select a file to save."""
    options = {}
    options['initialdir'] = strdir
    options['title'] = strtitle
    #options['defaultextension'] = '.txt'
    #options['filetypes'] = [('all files', '.*'), ('text files', '.txt')]
    options['initialfile'] = strfile
    #options['parent'] = root
    root = tkinter.Tk()
    root.withdraw()
    file_path = filedialog.asksaveasfile(**options)
    #same as: file_path = tkinter.filedialog.asksaveasfile(**options)
    return file_path
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号