Memo to PowerBASIC: it would be nice if the compiler would allow the exporting of a function with a specific ordinal number!

#COMPILE DLL #DIM ALL #OPTION VERSION4 #REGISTER NONE #INCLUDE "WIN32API.INC" FUNCTION LibMain( BYVAL hInstance AS LONG, BYVAL nReason AS LONG, BYVAL nReserved AS LONG ) EXPORT AS LONG SELECT CASE nReason CASE %DLL_PROCESS_ATTACH CALL Init( hInstance ) CASE %DLL_PROCESS_DETACH CALL CleanUp( hInstance ) END SELECT FUNCTION = %TRUE END FUNCTION SUB Init( BYVAL hInstance AS LONG ) 'Register classes END SUB SUB CleanUp( BYVAL hInstance AS LONG ) 'Unregister classes END SUB FUNCTION DoSomething( BYVAL sText AS STRING ) EXPORT AS LONG MSGBOX sText END FUNCTION
We process personal data about users of our site, through the use of cookies and other technologies, to deliver our services, and to analyze site activity. For additional details, refer to our Privacy Policy.
By clicking "I AGREE" below, you agree to our Privacy Policy and our personal data processing and cookie practices as described therein. You also acknowledge that this forum may be hosted outside your country and you consent to the collection, storage, and processing of your data in the country where this forum is hosted.
Leave a comment: