Page 1 of 1

handling "FMIFS.dll" with pb ???

Posted: Mon Dec 19, 2005 2:17 pm
by bingo
maybe a easy way to format any disk (usb-stick ...) ... :lol:

but how can handle this dll ?

The FormatEx function in FMIFS.DLL is prototyped like this:

VOID FormatEx( PWCHAR DriveRoot,
DWORD MediaFlag,
PWCHAR Format,
PWCHAR Label,
BOOL QuickFormat,
DWORD ClusterSize,
PFMIFSCALLBACK Callback );


The arguments are actually pretty self-explanatory. The callback function is used by FormatEx to communicate with its caller. The definition of PFMIFSCALLBACK is:

typedef BOOLEAN (__stdcall *PFMIFSCALLBACK)(
CALLBACKCOMMAND Command,
DWORD SubAction,
PVOID ActionInfo );


http://mvb.saic.com/freeware/vmslt99b/nt/fmifs.htm

Posted: Mon Dec 19, 2005 8:01 pm
by KarLKoX
Something like this ?

Code: Select all

Procedure.l Callback(Command.l, SubAction.l, *ActionInfo.l)

EndProcedure

Procedure PB_FormatEx(*DriverRoot.s, MediaFlag.l, *Format.s, *Label.s, QuickFormat.l, ClusterSize.l, *Callback.l)

Endprocedure
with *Callback.l = @Callback()