FileName="Trans." & amp; Org & amp; ". "& amp; Tmpdate & amp; "DAT" 'filename result is Trans. 0503.20141116. DAT
Filename=Application. GetSaveAsFileName (Filename, fileFilter:="Text Files (*. *), *. TXT")
Before this code under the Windows xp system running normally, but the unit equipment update for Windows 7, found the updated file can be generated, but the file name without generating, empty,
After the test, if in the file with "dot" (". ") cannot be used as the default file name, for example:
Filename=Application. GetSaveAsFileName (" abcdefg ", fileFilter:="Text Files (*. *), *. TXT") 'can run, file called abgdefg
Filename=Application. GetSaveAsFileName (ab. CD. Ef. "g", fileFilter:="Text Files (*. *), *. TXT") 'can run, but the file is called an empty
Please action ah, thank you very much,
CodePudding user response:
"Text Files (*. *), *. TXT")=="" Text Files (*.txt), *.txt")So you can (only need the TXT anyway, so in advance plus good) :
Filename=Application. GetSaveAsFilename (" ab. CD. Ef. G.t xt, fileFilter:="Text Files (*.txt), *. TXT")
CodePudding user response: