Private Sub Command1_Click() On Error GoTo MyError With CommonDialog1 .CancelError = True .DialogTitle = "Common Dialog Example" .Filter = "Text files only (*.txt)|*.txt|All files (*.*)|*.*" .FilterIndex = 1 .Flags = cdlOFNHideReadOnly Or cdlOFNOverwritePrompt Or cdlOFNPathMustExist .InitDir = App.Path .ShowSave End With 'Do your save stuff here 'Use the CommonDialog1.FileName property to get the full path and file name selected ' Exit Sub MyError: If Err.Number <> cdlCancel Then MsgBox Err.Number & " - " & Err.Description, vbOKOnly + vbExclamation, "Save" End If End Sub
จากคุณ
:
maddog [2011-12-16 00:25:28]
ความคิดเห็น #28538 (จาก IP: 202.29.229.18)
ขอบคุณมากครับอยากรู้เมื่อกันครับ
จากคุณ
:
BesT / nongbest_001@hotmail.com [2011-12-16 15:10:33]