how to open a file in some application using Tkinter i am using TKINTER to create GUI application i want to know how to open a word document in open office or any other applicatio
Fredrik Lundh
fredrik at pythonware.com
Wed Jan 9 03:24:34 EST 2008
brindly sujith wrote:
> i am using TKINTER to create GUI application
>
> i want to know how to open a word document in open office or any other
> application
>
> please send me the tkinter coding for this
reposting the reply you received when you posted this on another mailing
list:
---
on windows, you can use the "os.startfile" function:
import os
os.startfile("mydocument.doc")
(this is the same as double-clicking on a document in the file explorer)
on other platforms, use os.system() and specify what application to run:
import os
os.system("someapp mydocument.doc")
---
</F>
More information about the Python-list
mailing list