DG
Oct 31st, 2000, 03:25 PM
I am using the SHFormat drive API. I want to call a disk check routine when the API is complete. How can I postpone the call function until the API completes?
Code:
Private Sub Command5_Click()
Dim rtn As String
Dim Buffer As String
Dim WinPath As String
Buffer = String(255, 0)
rtn = GetWindowsDirectory(Buffer, Len(Buffer))
WinPath = Left(Trim(Buffer), rtn)
rtn = Shell(WinPath + "\rundll32.exe shell32.dll,SHFormatDrive", 1)
Call DiskCheck 'Need to wait here!!!!!
End Sub
Your help would be appreciated
Code:
Private Sub Command5_Click()
Dim rtn As String
Dim Buffer As String
Dim WinPath As String
Buffer = String(255, 0)
rtn = GetWindowsDirectory(Buffer, Len(Buffer))
WinPath = Left(Trim(Buffer), rtn)
rtn = Shell(WinPath + "\rundll32.exe shell32.dll,SHFormatDrive", 1)
Call DiskCheck 'Need to wait here!!!!!
End Sub
Your help would be appreciated