between code tags
:POINT
not between code tags :POINT This message was edited by Hiroshimator, on 2/1/2001 12:03:47 AM
Posted on 2001-02-01 00:02:00 by Hiroshimator
Checking the tags:


    indentation



   weird    spacing   here ; cause I want it like this
...-----....-------...----.-.-----.-.----.--.----.----


seeya
Posted on 2001-02-01 00:13:00 by Ernie
hmm it eats the first? and my net connection is gone with everything but netscape, can't even FTP or IRC what's up with that?
Posted on 2001-02-01 00:53:00 by Hiroshimator
et voila fixed
Posted on 2001-02-01 02:25:00 by Hiroshimator
;--------------------------------------------------------------------- ; the following prototypes are for polymorphic interface names, since ; MASM does not assosciate the ptr typedefs with a particular struct. ; ; These particular comflicting interfaces lead to the new name decoration ; ; problem interfaces (polymprphic) ; IDispatch_GetTypeInfo comethod4 ? ; IRecordInfo_GetTypeInfo comethod2 ? ; ITypeLib_GetTypeInfo comethod3 ? ; ;---------------------------------------------------------------------


option expr32
option casemap:none
option dotname

IFNDEF          OAIDL_INC
OAIDL_INC       EQU        1

;---------------------------------------------------------------------
; coinvoke MACRO 
;
; invokes an abritrary COM interface 
;
; revised 12/29/00 to check for edx as a param and force compilation error
;                   (thanks to Andy Car for a how-to suggestion)
; revised 7/18/00 to pass pointer in edx not eax to aviod confusion with
;   parmas passed with ADDR  (Jeremy Collake's excellent suggestion)
; revised 5/4/00 for member function name decoration
; see http://ourworld.compuserve.com/homepages/ernies_world/coinvoke.htm
;
; pInterface    pointer to a specific interface instance
; Interface     the Interface's struct typedef
; Function      which function or method of the interface to perform
; args          all required arguments 
;                   (type, kind and count determined by the function)
;
coinvoke MACRO pInterface:REQ, Interface:REQ, Function:REQ, args:VARARG
    LOCAL istatement, arg
    FOR arg,      ;; run thru args to see if edx is lurking in there
        IFIDNI <&arg>, 
            .ERR 
        ENDIF
    ENDM
    istatement CATSTR ,<_>,<&Function, pInterface>
    IFNB      ;; add the list of parameter arguments if any
        istatement CATSTR istatement, <, >, <&args> 
    ENDIF 
    mov edx, pInterface
    mov edx, 
    istatement
ENDM

 
;---------------------------------------------------------------------
; equate primitives for use with other structures besides .IF
SUCCEEDED   TEXTEQU     
FAILED      TEXTEQU     

;---------------------------------------------------------------------
; tests the value in eax to determine if the previous COM call
; issued a passing hresult
.IF_SUCCEEDED MACRO
    test eax, eax
    .IF SUCCEEDED
ENDM

;---------------------------------------------------------------------
; tests the value in eax to determine if the previous COM call
; issued a failing hresult
.IF_FAILED   MACRO
    test eax, eax
    .IF FAILED
ENDM

DECIMAL_SETZERO MACRO ddec:REQ
; #define DECIMAL_SETZERO(dec) {(dec).Lo64 = 0; (dec).Hi32 = 0; (dec).signscale = 0;}
    lea eax, ddec
    mov (DECIMAL PTR ).Lo32,  0
    mov (DECIMAL PTR ).Mid32, 0
    mov (DECIMAL PTR ).Hi32,  0
    mov (DECIMAL PTR ).signscale, 0
ENDM






L MACRO sText:REQ
    LOCAL str, chr, flag
    ;; generates a wide character string 
    ;; useage:       sztext   wchar   L()
    ;; generates:    sztext   WORD    "H","e","l","l","o","," ",
    ;;                                "W","o","r","l","d","!","!",0
    ;; max string length is 57 chars (MASM line length limit)
    ;;  use multiple non-zero term strings in sequence for longer strings
    ;;  (zero term the last of course)
        str  TEXTEQU < >
        flag TEXTEQU <.>
        FORC chr, <&sText> 
            IFDIF flag, <\>
                IFDIF str, < >
                    str CATSTR str, <,>
                ENDIF
            ENDIF
            IFDIF flag, <\>
                IFIDN <&chr>, <\>
                    flag CATSTR <\>
                ELSE
                    str CATSTR str, <">, <&chr>, <">
                ENDIF
            ELSE
                flag CATSTR  
                ;; check for a pipe (exclamation point)
                IFIDN <&ch
Posted on 2001-02-01 02:29:00 by Ernie