WinBatch Tech Support Home

Database Search

If you can't find the information using the categories below, post a question over in our WinBatch Tech Support Forum.

TechHome

Error Codes

Can't find the information you are looking for here? Then leave a message over on our WinBatch Tech Support Forum.

1028: Log Disk: Requested drive not online

Keywords:  dirremove 1028 log disk   

Question:

The following code:
   if DirExist("%SourceDir%")
       FileDelete("%SourceDir%\*.*")
       DirRemove("%SourceDir%")
   Endif
gives the error:
1028: LogDisk: Requested drive not online

  DirRemove("c:\win95\Start menu\Netwerk
  Programma's\Diverse applicaties\Multimedia")
After the program is stopped (OK button clicked in Error STOP dialog) the directory is removed from my hard drive!?

What am I doing wrong, The DirExist checks if the Dir exists and FileDelete is deleting all the files in the dir so dirremove has to work.

This code is a part of a script that syncs two dirs, one on a network drive and on the local harddisk.

Answer:

Try...
   DirChange("C:\")    
   Message(SourceDir,"Should NOT have a \ on the end for this code")
   if DirExist(SourceDir)
       FileDelete("%SourceDir%\*.*")
       DirRemove(SourceDir)
   Endif
My guess is that you were logged to the directory you were trying to delete. The Directory was removed, then WinBatch was lost as to where to be. The DirChange tell WinBatch to log to the C:\ directory. That will still be there so WinBatch will not be lost.
Article ID:   W12935
Filename:   1028 Log Disk DirRemove Error.txt
File Created: 1999:04:15:16:50:38
Last Updated: 1999:04:15:16:50:38