Hello Paul,
Looking at the generated code, it would appear that you don't have any provisions for the application returning a "status code" or "completion code". In fact, it looks as if you are returning a code that is never set.
QuoteFunction = msg.wParam
Msg is never referenced in WinMain except for the assignment above.
It looks like it would be rather easy to create a FF function to set the "status code" and then return that code in WinMain function. I will do it manually from a global variable for now.
Can't wait until FF3 is ready! ;D
David