- ©«¤l
- 5923
- ¥DÃD
- 13
- ºëµØ
- 1
- ¿n¤À
- 5986
- ÂI¦W
- 0
- §@·~¨t²Î
- win10
- ³nÅ骩¥»
- Office 2010
- ¾\ŪÅv
- 150
- ©Ê§O
- ¨k
- ¨Ó¦Û
- ¥xÆW°ò¶©
- µù¥U®É¶¡
- 2010-5-1
- ³Ì«áµn¿ý
- 2022-1-23
|
¦^´_ 3# enoch
On Error Resume Next °£«D½T©w¿ù»~ÂI¥i©¿²¤ ,§_«h¤£»´©ö¨Ï¥Î- Option Explicit
- Sub Ex()
- Dim xlMsg As String, Newfilename As String, xlSave As Integer
- Newfilename = "D:\TEST.XLS"
- xlMsg = IIf(Dir(Newfilename) <> "", "Âл\ÀÉ®×", "Àx¦sÀÉ®×")
- xlSave = MsgBox(Newfilename & Chr(10) & xlMsg & ":¬O(Y), ¥t¦sÀÉ®×:§_(N),¤£¦sÀÉ®×:¨ú®ø", vbYesNoCancel)
- 'xlSave ¶Ç¦^ vbYes, vbNo , vbCancel ¤T¿ï¤@
- Application.DisplayAlerts = False
- If xlSave = vbYes Then
- ActiveWorkbook.SaveAs Filename:=Newfilename
- ElseIf xlSave = vbNo Then
- With Application.FileDialog(msoFileDialogSaveAs)
- .InitialFileName = Newfilename
- If .Show = -1 Then ActiveWorkbook.SaveAs Filename:=.SelectedItems(1)
- End With
- End If
- Application.DisplayAlerts = True
- End Sub
½Æ»s¥N½X |
|