majjjj
چهارشنبه 21 آذر 1386, 11:17 صبح
Private Declare Function SHFileOperation Lib "shell32.dll" Alias " SHFileOperationA" (lpFileOp As SHFILEOPSTRUCT) As Long
ایا این تابع در کتابخانه shell32 وجود دارد اگه جواب مثبته چرا برنامه من اونو نمیشناسه
Private Const FO_COPY = &H2
Private Type SHFILEOPSTRUCT
hwnd As Long
wFunc As Long
pFrom As String
pTo As String
fFlags As Integer
fAnyOperationsAborted As Long
hNameMappings As Long
lpszProgressTitle As String ' only used if FOF_SIMPLEPROGRESS
End Type
Private Declare Function SHFileOperation Lib "shell32.dll" Alias " SHFileOperationA" (lpFileOp As SHFILEOPSTRUCT) As Long
Private Sub Command1_Click()
Dim ret_val As Long
Dim sh_op As SHFILEOPSTRUCT
With sh_op
.hwnd = 0
.wFunc = FO_COPY
.pFrom = Text1.Text
.pTo = Text2.Text
End With
ret_val = SHFileOperation(sh_op)
End Sub
Private Sub Form_Load()
Command1.Caption = "ersal"
End Sub
ایا این تابع در کتابخانه shell32 وجود دارد اگه جواب مثبته چرا برنامه من اونو نمیشناسه
Private Const FO_COPY = &H2
Private Type SHFILEOPSTRUCT
hwnd As Long
wFunc As Long
pFrom As String
pTo As String
fFlags As Integer
fAnyOperationsAborted As Long
hNameMappings As Long
lpszProgressTitle As String ' only used if FOF_SIMPLEPROGRESS
End Type
Private Declare Function SHFileOperation Lib "shell32.dll" Alias " SHFileOperationA" (lpFileOp As SHFILEOPSTRUCT) As Long
Private Sub Command1_Click()
Dim ret_val As Long
Dim sh_op As SHFILEOPSTRUCT
With sh_op
.hwnd = 0
.wFunc = FO_COPY
.pFrom = Text1.Text
.pTo = Text2.Text
End With
ret_val = SHFileOperation(sh_op)
End Sub
Private Sub Form_Load()
Command1.Caption = "ersal"
End Sub