openfiledialog を開いた状態でディレクトリを変更する方法を教えてください。特定のディレクトリに設定したいです。
def OnOpen(self,event):
"""Open a file"""
openFileDialog = wx.FileDialog(self,"Open log file","","","Log files (*.log)|*.log",wx.FD_OPEN | wx.FD_FILE_MUST_EXIST |wx.FD_CHANGE_DIR)
if openFileDialog.ShowModal() == wx.ID_CANCEL:
return
input_stream = wx.FileInputStream(openFileDialog.GetPath())
if not input_stream.IsOk():
wx.LogError("Cannot open file '%s'."%openFileDialog.GetPath())
return
setdirectory などの関数を見たことがありますが、そのパラメータをどこに適用すればよいかわかりません。