private declare function shformatdrive lib"shell32"_ ( byval hend as long,_ byval drive as long,_ byval formatid as long,_ byval options as long) as long
private sub formatdisk(intdrive as integer,blnquickformat as boolean) dim lngreturn as long;
if (blnquickformat) then lngreturn= shformatdrive(0,intdrive,0&,1&) else lngreturn= shformatdrive(0,intdrive,0&,0&) end if end sub
private sub command1_click() call formatdisk(0,true) end sub