im using a timer to process a few lines of code at certain intervals.
invoke SetTimer,hWin,5,500,NULL


		   invoke SendMessage,hListBox0,LB_RESETCONTENT,0,0
         invoke EnumWindows,addr EnumProc,NULL


EnumProc proc eHandle:DWORD

invoke GetClassName,eHandle,ADDR clName,8
invoke lstrcmpi,addr clName, addr IEFrame
	.if eax == 0
	    invoke IsWindowVisible,eHandle
            .if eax
                invoke GetWindowText,eHandle,addr buffer,100
                    .if eax
                        invoke SendMessage,hListBox0,LB_ADDSTRING,NULL,addr buffer
mov eax,eHandle

EnumProc endp
It appears that the line mov eax,eHandle is the problem. When i change this line to xor eax,eax the program doesnt crash but it also doesnt do what its suppose to do. anyone? The error message box stated:
The instruction at "ox77e14abb" referenced memory at "0x00000000". The memory count not be "written".


This message was edited by smurf, on 6/7/2001 6:19:51 AM
Posted on 2001-06-07 06:11:00 by smurf
To continue enumeration, the callback function must return TRUE; to stop enumeration, it must return FALSE.
Posted on 2001-06-07 06:18:00 by Iczelion
oops This message was edited by smurf, on 6/7/2001 11:33:00 AM
Posted on 2001-06-07 06:25:00 by smurf
the type of your enum proc (as a parameter for EnumWindows()) should be: EnumWindowsProc proc stdcall hWnd:dword,lParam:dword so actually your proc is missing one parameter hope this will help
Posted on 2001-06-07 10:58:00 by Japheth
thanks japheth that was my problem. i didnt realize that i needed to have all the parameters defined even though i wasnt gonna use them. :) thanks again smurf
Posted on 2001-06-07 11:38:00 by smurf