Hi,
Attached is the code I am working on. Note the section under the WndProc that points out the error.
When this part is uncommencted and the source built. If you run the app, and you click on any of the edit boxes the program terminates.
Anyone see something that I am missing, forgot or did wrong?
jInuQ
Attached is the code I am working on. Note the section under the WndProc that points out the error.
When this part is uncommencted and the source built. If you run the app, and you click on any of the edit boxes the program terminates.
Anyone see something that I am missing, forgot or did wrong?
jInuQ
i can't manage to terminate the program nor when two lines are commented nor when they are uncomented, but i see two things here
first:
at ..WMCOMMAND you don't have default handler, it should look something like :
and then (maybe this is what causes termination)
in Convert ..GOTDEC: you are using ConvertText as a 4 bytes buffer and then as a pointer to a buffer??
if you want to use it as a buffer:
or as a pointer to a buffer:
first:
at ..WMCOMMAND you don't have default handler, it should look something like :
....
cmp ax, IDM_ABOUT
je ..CMDABOUT
xor eax,eax ;or you can jmp DEFWINPROC here
jmp .FINISH ;
..CMDCONVERT:
and then (maybe this is what causes termination)
in Convert ..GOTDEC: you are using ConvertText as a 4 bytes buffer and then as a pointer to a buffer??
invoke GetDlgItemText, [hAppWnd], DecEditC, ConvertText, 4
mov eax, [ConvertText] ; error here
invoke SetDlgItemText, [hAppWnd], DecEditC, eax
if you want to use it as a buffer:
invoke GetDlgItemText, [hAppWnd], DecEditC, ConvertText, 4
mov eax, ConvertText
invoke SetDlgItemText, [hAppWnd], DecEditC, eax
or as a pointer to a buffer:
invoke GetDlgItemText, [hAppWnd], DecEditC, [ConvertText],[ConvertTextSize]
mov eax, [ConvertText]
invoke SetDlgItemText, [hAppWnd], DecEditC, eax
Thanks for the help, will look and see if it makes any difference.