The FileSystemObject provides a GetTempName method that returns a temporary file name. The following is the short example, in VBScript on Windows Scripting Host.
1 2 3 4 5 6 7 8 | ' Auto-Generate a File Name Set objFSO = CreateObject("Scripting.FileSystemObject") For i = 1 to 10 strTempFile = objFSO.GetTempName Wscript.Echo strTempFile Next |
' Auto-Generate a File Name Set objFSO = CreateObject("Scripting.FileSystemObject") For i = 1 to 10 strTempFile = objFSO.GetTempName Wscript.Echo strTempFile Next
–EOF (The Ultimate Computing & Technology Blog) —
GD Star Rating
loading...
91 wordsloading...
Last Post: Bubble Sort in VBScript
Next Post: Using XMLHTTP in VBScript