国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁(yè) > 開發(fā) > JS > 正文

Save a File Using a File Save Dialog Box

2024-09-06 12:42:08
字體:
來(lái)源:轉(zhuǎn)載
供稿:網(wǎng)友
Demonstration script that allows you to enter a file name in a File Save dialog box, and then saves a sample text file (consisting entirely of the current date) under that file name. 

Supported Platforms

Windows Server 2003
 No

Windows XP
 Yes

Windows 2000
 No

Windows NT 4.0
 No

Windows 98
 No


Script Code

代碼如下:
Set objDialog = CreateObject("SAFRCFileDlg.FileSave") 

objDialog.FileName = "C:/Scripts/Script1.vbs" 
objDialog.FileType = "VBScript Script" 
intReturn = objDialog.OpenFileSaveDlg 

If intReturn Then 
    Set objFSO = CreateObject("Scripting.FileSystemObject") 
    Set objFile = objFSO.CreateTextFile(objDialog.FileName) 
    objFile.WriteLine Date 
    objFile.Close 
Else 
    Wscript.Quit 
End If 
發(fā)表評(píng)論 共有條評(píng)論
用戶名: 密碼:
驗(yàn)證碼: 匿名發(fā)表
主站蜘蛛池模板: 兴山县| 视频| 庄河市| 宁南县| 厦门市| 青海省| 元阳县| 喜德县| 阿尔山市| 杭锦后旗| 京山县| 石嘴山市| 九江县| 科尔| 溧水县| 百色市| 昌宁县| 门源| 舒兰市| 永登县| 英超| 青海省| 祁门县| 天长市| 荣昌县| 庆云县| 朝阳市| 唐河县| 宁阳县| 若羌县| 大安市| 临朐县| 泸水县| 红原县| 綦江县| 东阳市| 太保市| 边坝县| 河西区| 宝应县| 浦东新区|