` How to create an "Application CLASS" that is compiled and linked into a DLL (Dave Berton ) - Icetips Article
Icetips - Templates, Tools & Utilities for Clarion Developers

Templates, Tools and Utilities
for Clarion Developers

Icetips Article

Back to article list   Search Articles     Add Comment     Printer friendly     Direct link  

Par2: How to create an "Application CLASS" that is compiled and linked into a DLL
1998-06-26 -- Dave Berton
 
is the solution we use - an 'Object Exporter' template which will allow you to easily export objects and methods from the object DLLs you create. #INCLUDE() this in an existing template chain: --begin objexp.tpw #EXTENSION(ObjectExporter,'Export Objects from a DLL'),APPLICATION #DISPLAY('') #DISPLAY('Export selected objects from this DLL.') #DISPLAY('') #DISPLAY('Insert all objects and methods here:') #BUTTON('Objects'),MULTI(%ObjectsToExport,%ExportedObject),INLINE #PROMPT('Object',@S50),%ExportedObject,REQ #DISPLAY('') #DISPLAY('Object methods to export:') #BUTTON('Exported methods'),MULTI(%ExportedMethods,%MethodName & ' ' & %MethodPrototype),INLINE #PROMPT('Method',@S100),%MethodName,AT(,,100) #PROMPT('Prototype',@S255),%MethodPrototype,AT(,,100) #ENDBUTTON #ENDBUTTON #ATSTART #DECLARE(%ObjectMethodPrototype) #ENDAT #AT(%DLLExportList) ;Start of Object Exporter #FOR(%ObjectsToExport) #SET(%ExportedObject,UPPER(%ExportedObject)) TYPE$%ExportedObject @? VMT$%ExportedObject @? #FOR(%ExportedMethods) #IF(SUB(%MethodPrototype,1,1) = '(') #SET(%ObjectMethodPrototype,SUB(%MethodPrototype,1,1) & %ExportedObject & ',' & SUB(%MethodPrototype,2,LEN(CLIP(%MethodPrototype)))) #ELSE #SET(%ObjectMethodPrototype,'(' & %ExportedObject & ')') #ENDIF %(LINKNAME(%MethodName & %ObjectMethodPrototype)) @? #ENDFOR #ENDFOR ;End of Object Exporter #ENDAT


Today is April 27, 2024, 12:12 pm
This article has been viewed 35113 times.



Back to article list   Search Articles   Add Comment   Printer friendly

Login

User Name:

Password: