%include "\lab\vasm\inc\nagoa.inc"
bss32
hInstance resd 1
data32
ID_DIALOG equ 100
IDC_TRB1 equ 1001
IDC_EDT1 equ 1002
ID_close_button equ 2
code32
..start:
invoke GetModuleHandle,NULL
mov ,eax
invoke InitCommonControls
invoke DialogBoxParam,,ID_DIALOG,NULL,DlgProc,NULL
invoke ExitProcess,0
proc DlgProc , hdlg , uMsg , wParam , lParam
if dword ,e,WM_INITDIALOG
invoke SendDlgItemMessage,,IDC_TRB1,TBM_SETRANGEMIN,FALSE,0
invoke SendDlgItemMessage,,IDC_TRB1,TBM_SETRANGEMAX,FALSE,20
return TRUE
endif
if dword ,e,WM_COMMAND
if dword ,e,ID_close_button
invoke SendMessage,,WM_CLOSE,0,0
endif
return TRUE
endif
if dword ,e,WM_HSCROLL
invoke SendDlgItemMessage,,IDC_TRB1,TBM_GETPOS,0,0
invoke SetDlgItemInt,,IDC_EDT1,eax,FALSE
return TRUE
endif
if dword ,e,WM_CLOSE
invoke EndDialog,,0
return TRUE
endif
return FALSE
endproc DlgProc
made in NAGOA
update yesterday i think
bss32
hInstance resd 1
data32
ID_DIALOG equ 100
IDC_TRB1 equ 1001
IDC_EDT1 equ 1002
ID_close_button equ 2
code32
..start:
invoke GetModuleHandle,NULL
mov ,eax
invoke InitCommonControls
invoke DialogBoxParam,,ID_DIALOG,NULL,DlgProc,NULL
invoke ExitProcess,0
proc DlgProc , hdlg , uMsg , wParam , lParam
if dword ,e,WM_INITDIALOG
invoke SendDlgItemMessage,,IDC_TRB1,TBM_SETRANGEMIN,FALSE,0
invoke SendDlgItemMessage,,IDC_TRB1,TBM_SETRANGEMAX,FALSE,20
return TRUE
endif
if dword ,e,WM_COMMAND
if dword ,e,ID_close_button
invoke SendMessage,,WM_CLOSE,0,0
endif
return TRUE
endif
if dword ,e,WM_HSCROLL
invoke SendDlgItemMessage,,IDC_TRB1,TBM_GETPOS,0,0
invoke SetDlgItemInt,,IDC_EDT1,eax,FALSE
return TRUE
endif
if dword ,e,WM_CLOSE
invoke EndDialog,,0
return TRUE
endif
return FALSE
endproc DlgProc
made in NAGOA
update yesterday i think
%include "\lab\vasm\inc\nagoa.inc"
bss32
iccex resb INITCOMMONCONTROLSEX_size
hInstance resd 1
data32
iccex.dwSize equ iccex + 0
iccex.dwICC equ iccex + 4
IDD_DLG equ 1000
code32
..start:
invoke GetModuleHandle,NULL
mov ,eax
invoke InitCommonControls
mov dword ,INITCOMMONCONTROLSEX_size
mov dword ,ICC_DATE_CLASSES
invoke InitCommonControlsEx,iccex
invoke DialogBoxParam,,IDD_DLG,NULL,DlgProc,NULL
invoke ExitProcess,0
proc DlgProc , hWin , uMsg , wParam , lParam
if dword ,e,WM_INITDIALOG
return TRUE
endif
if dword ,e,WM_COMMAND
return TRUE
endif
if dword ,e,WM_CLOSE
invoke EndDialog,,0
endif
return FALSE
endproc DlgProc
bss32
iccex resb INITCOMMONCONTROLSEX_size
hInstance resd 1
data32
iccex.dwSize equ iccex + 0
iccex.dwICC equ iccex + 4
IDD_DLG equ 1000
code32
..start:
invoke GetModuleHandle,NULL
mov ,eax
invoke InitCommonControls
mov dword ,INITCOMMONCONTROLSEX_size
mov dword ,ICC_DATE_CLASSES
invoke InitCommonControlsEx,iccex
invoke DialogBoxParam,,IDD_DLG,NULL,DlgProc,NULL
invoke ExitProcess,0
proc DlgProc , hWin , uMsg , wParam , lParam
if dword ,e,WM_INITDIALOG
return TRUE
endif
if dword ,e,WM_COMMAND
return TRUE
endif
if dword ,e,WM_CLOSE
invoke EndDialog,,0
endif
return FALSE
endproc DlgProc
and the point of this is?
Hi ZobySound,
Are you having a problem or was it just to show that you can use a DlgProc. If it is just to demonstrate the DlgProc I think most people here are capable of using one. Like evlncrn8, I have to ask what the point of this was. If it was a code demonstration it should be in the Algorithms and source code section, but it is fairly simple code so I doubt it would be useful to many.
Are you having a problem or was it just to show that you can use a DlgProc. If it is just to demonstrate the DlgProc I think most people here are capable of using one. Like evlncrn8, I have to ask what the point of this was. If it was a code demonstration it should be in the Algorithms and source code section, but it is fairly simple code so I doubt it would be useful to many.
You failed to mention it should be in
tags as well