powerbuilder send message control

Powerbuilder 對於視窗形物件的控制比起 C/C++/C#/VB 等開發工具弱勢多了。

但是,Powerbuilder 提供了 Send 函數來彌補對視窗物件的一些細微控制。
其實,它是源自於 Windows 本身對於標準 Windows 物件的控制,它是使用了 Message ID 方式通知物件進形事件動作,而 Powerbuilder 只是順便利用了這個設計而已。

例如:ListView 為人詬病的就是缺了 Scroll 的控制,在資料量大時,一定會超過一個畫面的資料,會跑到畫面之外,此時你只能用滑鼠去 Scroll 或是用滑鼠操作 Scroll bar ,沒有辦法用 Programming 方式控制。

此時,就可以利用 Windows Message 方式發送控制資訊給 Windows物件 來控制:


//捲動功能,可適用在ListView、DataWindow、MulitiLine Editor上
//上捲一行
Send(Handle(lv_mylist), 277, 0, 0)
//上捲一頁
Send(Handle(lv_mylist), 277, 2, 0)
//下捲一行
Send(Handle(lv_mylist), 277, 1, 0)
//下捲一頁
Send(Handle(lv_mylist), 277, 3, 0)

//像是下面兩種方式都可觸發按鈕Click事件
Send(Handle(Parent), 273, 0, Handle(cb_OK))
cb_OK.TriggerEvent(Clicked!)

//最小化 DataWindow
Send(Handle(dw_whatever), 274, 61472, 0)
//最大化 DataWindow
Send(Handle(dw_whatever), 274, 61488, 0)
//一般大小 DataWindow
Send(Handle(dw_whatever), 274, 61728, 0)





Windows Message ID 參考列表:
注意同一個ID可能出現多次,是因為同一個ID在不同控件上是不同的意義,此時請看前綴英文字的代表意義。
HexDecimalSymbolic
00000WM_NULL
00011WM_CREATE
00022WM_DESTROY
00033WM_MOVE
00055WM_SIZE
00066WM_ACTIVATE
00077WM_SETFOCUS
00088WM_KILLFOCUS
000a10WM_ENABLE
000b11WM_SETREDRAW
000c12WM_SETTEXT
000d13WM_GETTEXT
000e14WM_GETTEXTLENGTH
000f15WM_PAINT
001016WM_CLOSE
001117WM_QUERYENDSESSION
001218WM_QUIT
001319WM_QUERYOPEN
001420WM_ERASEBKGND
001521WM_SYSCOLORCHANGE
001622WM_ENDSESSION
001824WM_SHOWWINDOW
001925WM_CTLCOLOR
001a26WM_WININICHANGE
001b27WM_DEVMODECHANGE
001c28WM_ACTIVATEAPP
001d29WM_FONTCHANGE
001e30WM_TIMECHANGE
001f31WM_CANCELMODE
002032WM_SETCURSOR
002133WM_MOUSEACTIVATE
002234WM_CHILDACTIVATE
002335WM_QUEUESYNC
002436WM_GETMINMAXINFO
002638WM_PAINTICON
002739WM_ICONERASEBKGND
002840WM_NEXTDLGCTL
002a42WM_SPOOLERSTATUS
002b43WM_DRAWITEM
002c44WM_MEASUREITEM
002d45WM_DELETEITEM
002e46WM_VKEYTOITEM
002f47WM_CHARTOITEM
003048WM_SETFONT
003149WM_GETFONT
003250WM_SETHOTKEY
003351WM_GETHOTKEY
003755WM_QUERYDRAGICON
003957WM_COMPAREITEM
003d61WM_GETOBJECT
004165WM_COMPACTING
004468WM_COMMNOTIFY
004670WM_WINDOWPOSCHANGING
004771WM_WINDOWPOSCHANGED
004872WM_POWER
004973WM_COPYGLOBALDATA
004a74WM_COPYDATA
004b75WM_CANCELJOURNAL
004e78WM_NOTIFY
005080WM_INPUTLANGCHANGEREQUEST
005181WM_INPUTLANGCHANGE
005282WM_TCARD
005383WM_HELP
005484WM_USERCHANGED
005585WM_NOTIFYFORMAT
007b123WM_CONTEXTMENU
007c124WM_STYLECHANGING
007d125WM_STYLECHANGED
007e126WM_DISPLAYCHANGE
007f127WM_GETICON
0080128WM_SETICON
0081129WM_NCCREATE
0082130WM_NCDESTROY
0083131WM_NCCALCSIZE
0084132WM_NCHITTEST
0085133WM_NCPAINT
0086134WM_NCACTIVATE
0087135WM_GETDLGCODE
0088136WM_SYNCPAINT
00a0160WM_NCMOUSEMOVE
00a1161WM_NCLBUTTONDOWN
00a2162WM_NCLBUTTONUP
00a3163WM_NCLBUTTONDBLCLK
00a4164WM_NCRBUTTONDOWN
00a5165WM_NCRBUTTONUP
00a6166WM_NCRBUTTONDBLCLK
00a7167WM_NCMBUTTONDOWN
00a8168WM_NCMBUTTONUP
00a9169WM_NCMBUTTONDBLCLK
00ab171WM_NCXBUTTONDOWN
00ac172WM_NCXBUTTONUP
00ad173WM_NCXBUTTONDBLCLK
00b0176EM_GETSEL
00b1177EM_SETSEL
00b2178EM_GETRECT
00b3179EM_SETRECT
00b4180EM_SETRECTNP
00b5181EM_SCROLL
00b6182EM_LINESCROLL
00b7183EM_SCROLLCARET
00b8185EM_GETMODIFY
00b9187EM_SETMODIFY
00ba188EM_GETLINECOUNT
00bb189EM_LINEINDEX
00bc190EM_SETHANDLE
00bd191EM_GETHANDLE
00be192EM_GETTHUMB
00c1193EM_LINELENGTH
00c2194EM_REPLACESEL
00c3195EM_SETFONT
00c4196EM_GETLINE
00c5197EM_LIMITTEXT
00c5197EM_SETLIMITTEXT
00c6198EM_CANUNDO
00c7199EM_UNDO
00c8200EM_FMTLINES
00c9201EM_LINEFROMCHAR
00ca202EM_SETWORDBREAK
00cb203EM_SETTABSTOPS
00cc204EM_SETPASSWORDCHAR
00cd205EM_EMPTYUNDOBUFFER
00ce206EM_GETFIRSTVISIBLELINE
00cf207EM_SETREADONLY
00d0209EM_SETWORDBREAKPROC
00d1209EM_GETWORDBREAKPROC
00d2210EM_GETPASSWORDCHAR
00d3211EM_SETMARGINS
00d4212EM_GETMARGINS
00d5213EM_GETLIMITTEXT
00d6214EM_POSFROMCHAR
00d7215EM_CHARFROMPOS
00d8216EM_SETIMESTATUS
00d9217EM_GETIMESTATUS
00e0224SBM_SETPOS
00e1225SBM_GETPOS
00e2226SBM_SETRANGE
00e3227SBM_GETRANGE
00e4228SBM_ENABLE_ARROWS
00e6230SBM_SETRANGEREDRAW
00e9233SBM_SETSCROLLINFO
00ea234SBM_GETSCROLLINFO
00eb235SBM_GETSCROLLBARINFO
00f0240BM_GETCHECK
00f1241BM_SETCHECK
00f2242BM_GETSTATE
00f3243BM_SETSTATE
00f4244BM_SETSTYLE
00f5245BM_CLICK
00f6246BM_GETIMAGE
00f7247BM_SETIMAGE
00f8248BM_SETDONTCLICK
00ff255WM_INPUT
0100256WM_KEYDOWN
0100256WM_KEYFIRST
0101257WM_KEYUP
0102258WM_CHAR
0103259WM_DEADCHAR
0104260WM_SYSKEYDOWN
0105261WM_SYSKEYUP
0106262WM_SYSCHAR
0107263WM_SYSDEADCHAR
0108264WM_KEYLAST
0109265WM_UNICHAR
0109265WM_WNT_CONVERTREQUESTEX
010a266WM_CONVERTREQUEST
010b267WM_CONVERTRESULT
010c268WM_INTERIM
010d269WM_IME_STARTCOMPOSITION
010e270WM_IME_ENDCOMPOSITION
010f271WM_IME_COMPOSITION
010f271WM_IME_KEYLAST
0110272WM_INITDIALOG
0111273WM_COMMAND
0112274WM_SYSCOMMAND
0113275WM_TIMER
0114276WM_HSCROLL
0115277WM_VSCROLL
0116278WM_INITMENU
0117279WM_INITMENUPOPUP
0118280WM_SYSTIMER
011f287WM_MENUSELECT
0120288WM_MENUCHAR
0121289WM_ENTERIDLE
0122290WM_MENURBUTTONUP
0123291WM_MENUDRAG
0124292WM_MENUGETOBJECT
0125293WM_UNINITMENUPOPUP
0126294WM_MENUCOMMAND
0127295WM_CHANGEUISTATE
0128296WM_UPDATEUISTATE
0129297WM_QUERYUISTATE
0132306WM_CTLCOLORMSGBOX
0133307WM_CTLCOLOREDIT
0134308WM_CTLCOLORLISTBOX
0135309WM_CTLCOLORBTN
0136310WM_CTLCOLORDLG
0137311WM_CTLCOLORSCROLLBAR
0138312WM_CTLCOLORSTATIC
0200512WM_MOUSEFIRST
0200512WM_MOUSEMOVE
0201513WM_LBUTTONDOWN
0202514WM_LBUTTONUP
0203515WM_LBUTTONDBLCLK
0204516WM_RBUTTONDOWN
0205517WM_RBUTTONUP
0206518WM_RBUTTONDBLCLK
0207519WM_MBUTTONDOWN
0208520WM_MBUTTONUP
0209521WM_MBUTTONDBLCLK
0209521WM_MOUSELAST
020a522WM_MOUSEWHEEL
020b523WM_XBUTTONDOWN
020c524WM_XBUTTONUP
020d525WM_XBUTTONDBLCLK
0210528WM_PARENTNOTIFY
0211529WM_ENTERMENULOOP
0212530WM_EXITMENULOOP
0213531WM_NEXTMENU
0214532WM_SIZING
0215533WM_CAPTURECHANGED
0216534WM_MOVING
0218536WM_POWERBROADCAST
0219537WM_DEVICECHANGE
0220544WM_MDICREATE
0221545WM_MDIDESTROY
0222546WM_MDIACTIVATE
0223547WM_MDIRESTORE
0224548WM_MDINEXT
0225549WM_MDIMAXIMIZE
0226550WM_MDITILE
0227551WM_MDICASCADE
0228552WM_MDIICONARRANGE
0229553WM_MDIGETACTIVE
0230560WM_MDISETMENU
0231561WM_ENTERSIZEMOVE
0232562WM_EXITSIZEMOVE
0233563WM_DROPFILES
0234564WM_MDIREFRESHMENU
0280640WM_IME_REPORT
0281641WM_IME_SETCONTEXT
0282642WM_IME_NOTIFY
0283643WM_IME_CONTROL
0284644WM_IME_COMPOSITIONFULL
0285645WM_IME_SELECT
0286646WM_IME_CHAR
0288648WM_IME_REQUEST
0290656WM_IMEKEYDOWN
0290656WM_IME_KEYDOWN
0291657WM_IMEKEYUP
0291657WM_IME_KEYUP
02a0672WM_NCMOUSEHOVER
02a1673WM_MOUSEHOVER
02a2674WM_NCMOUSELEAVE
02a3675WM_MOUSELEAVE
0300768WM_CUT
0301769WM_COPY
0302770WM_PASTE
0303771WM_CLEAR
0304772WM_UNDO
0305773WM_RENDERFORMAT
0306774WM_RENDERALLFORMATS
0307775WM_DESTROYCLIPBOARD
0308776WM_DRAWCLIPBOARD
0309777WM_PAINTCLIPBOARD
030a778WM_VSCROLLCLIPBOARD
030b779WM_SIZECLIPBOARD
030c780WM_ASKCBFORMATNAME
030d781WM_CHANGECBCHAIN
030e782WM_HSCROLLCLIPBOARD
030f783WM_QUERYNEWPALETTE
0310784WM_PALETTEISCHANGING
0311785WM_PALETTECHANGED
0312786WM_HOTKEY
0317791WM_PRINT
0318792WM_PRINTCLIENT
0319793WM_APPCOMMAND
0358856WM_HANDHELDFIRST
035f863WM_HANDHELDLAST
0360864WM_AFXFIRST
037f895WM_AFXLAST
0380896WM_PENWINFIRST
0381897WM_RCRESULT
0382898WM_HOOKRCRESULT
0383899WM_GLOBALRCCHANGE
0383899WM_PENMISCINFO
0384900WM_SKB
0385901WM_HEDITCTL
0385901WM_PENCTL
0386902WM_PENMISC
0387903WM_CTLINIT
0388904WM_PENEVENT
038f911WM_PENWINLAST
04001024DDM_SETFMT
04001024DM_GETDEFID
04001024NIN_SELECT
04001024TBM_GETPOS
04001024WM_PSD_PAGESETUPDLG
04001024WM_USER
04011025CBEM_INSERTITEMA
04011025DDM_DRAW
04011025DM_SETDEFID
04011025HKM_SETHOTKEY
04011025PBM_SETRANGE
04011025RB_INSERTBANDA
04011025SB_SETTEXTA
04011025TB_ENABLEBUTTON
04011025TBM_GETRANGEMIN
04011025TTM_ACTIVATE
04011025WM_CHOOSEFONT_GETLOGFONT
04011025WM_PSD_FULLPAGERECT
04021026CBEM_SETIMAGELIST
04021026DDM_CLOSE
04021026DM_REPOSITION
04021026HKM_GETHOTKEY
04021026PBM_SETPOS
04021026RB_DELETEBAND
04021026SB_GETTEXTA
04021026TB_CHECKBUTTON
04021026TBM_GETRANGEMAX
04021026WM_PSD_MINMARGINRECT
04031027CBEM_GETIMAGELIST
04031027DDM_BEGIN
04031027HKM_SETRULES
04031027PBM_DELTAPOS
04031027RB_GETBARINFO
04031027SB_GETTEXTLENGTHA
04031027TBM_GETTIC
04031027TB_PRESSBUTTON
04031027TTM_SETDELAYTIME
04031027WM_PSD_MARGINRECT
04041028CBEM_GETITEMA
04041028DDM_END
04041028PBM_SETSTEP
04041028RB_SETBARINFO
04041028SB_SETPARTS
04041028TB_HIDEBUTTON
04041028TBM_SETTIC
04041028TTM_ADDTOOLA
04041028WM_PSD_GREEKTEXTRECT
04051029CBEM_SETITEMA
04051029PBM_STEPIT
04051029TB_INDETERMINATE
04051029TBM_SETPOS
04051029TTM_DELTOOLA
04051029WM_PSD_ENVSTAMPRECT
04061030CBEM_GETCOMBOCONTROL
04061030PBM_SETRANGE32
04061030RB_SETBANDINFOA
04061030SB_GETPARTS
04061030TB_MARKBUTTON
04061030TBM_SETRANGE
04061030TTM_NEWTOOLRECTA
04061030WM_PSD_YAFULLPAGERECT
04071031CBEM_GETEDITCONTROL
04071031PBM_GETRANGE
04071031RB_SETPARENT
04071031SB_GETBORDERS
04071031TBM_SETRANGEMIN
04071031TTM_RELAYEVENT
04081032CBEM_SETEXSTYLE
04081032PBM_GETPOS
04081032RB_HITTEST
04081032SB_SETMINHEIGHT
04081032TBM_SETRANGEMAX
04081032TTM_GETTOOLINFOA
04091033CBEM_GETEXSTYLE
04091033CBEM_GETEXTENDEDSTYLE
04091033PBM_SETBARCOLOR
04091033RB_GETRECT
04091033SB_SIMPLE
04091033TB_ISBUTTONENABLED
04091033TBM_CLEARTICS
04091033TTM_SETTOOLINFOA
040a1034CBEM_HASEDITCHANGED
040a1034RB_INSERTBANDW
040a1034SB_GETRECT
040a1034TB_ISBUTTONCHECKED
040a1034TBM_SETSEL
040a1034TTM_HITTESTA
040a1034WIZ_QUERYNUMPAGES
040b1035CBEM_INSERTITEMW
040b1035RB_SETBANDINFOW
040b1035SB_SETTEXTW
040b1035TB_ISBUTTONPRESSED
040b1035TBM_SETSELSTART
040b1035TTM_GETTEXTA
040b1035WIZ_NEXT
040c1036CBEM_SETITEMW
040c1036RB_GETBANDCOUNT
040c1036SB_GETTEXTLENGTHW
040c1036TB_ISBUTTONHIDDEN
040c1036TBM_SETSELEND
040c1036TTM_UPDATETIPTEXTA
040c1036WIZ_PREV
040d1037CBEM_GETITEMW
040d1037RB_GETROWCOUNT
040d1037SB_GETTEXTW
040d1037TB_ISBUTTONINDETERMINATE
040d1037TTM_GETTOOLCOUNT
040e1038CBEM_SETEXTENDEDSTYLE
040e1038RB_GETROWHEIGHT
040e1038SB_ISSIMPLE
040e1038TB_ISBUTTONHIGHLIGHTED
040e1038TBM_GETPTICS
040e1038TTM_ENUMTOOLSA
040f1039SB_SETICON
040f1039TBM_GETTICPOS
040f1039TTM_GETCURRENTTOOLA
04101040RB_IDTOINDEX
04101040SB_SETTIPTEXTA
04101040TBM_GETNUMTICS
04101040TTM_WINDOWFROMPOINT
04111041RB_GETTOOLTIPS
04111041SB_SETTIPTEXTW
04111041TBM_GETSELSTART
04111041TB_SETSTATE
04111041TTM_TRACKACTIVATE
04121042RB_SETTOOLTIPS
04121042SB_GETTIPTEXTA
04121042TB_GETSTATE
04121042TBM_GETSELEND
04121042TTM_TRACKPOSITION
04131043RB_SETBKCOLOR
04131043SB_GETTIPTEXTW
04131043TB_ADDBITMAP
04131043TBM_CLEARSEL
04131043TTM_SETTIPBKCOLOR
04141044RB_GETBKCOLOR
04141044SB_GETICON
04141044TB_ADDBUTTONSA
04141044TBM_SETTICFREQ
04141044TTM_SETTIPTEXTCOLOR
04151045RB_SETTEXTCOLOR
04151045TB_INSERTBUTTONA
04151045TBM_SETPAGESIZE
04151045TTM_GETDELAYTIME
04161046RB_GETTEXTCOLOR
04161046TB_DELETEBUTTON
04161046TBM_GETPAGESIZE
04161046TTM_GETTIPBKCOLOR
04171047RB_SIZETORECT
04171047TB_GETBUTTON
04171047TBM_SETLINESIZE
04171047TTM_GETTIPTEXTCOLOR
04181048RB_BEGINDRAG
04181048TB_BUTTONCOUNT
04181048TBM_GETLINESIZE
04181048TTM_SETMAXTIPWIDTH
04191049RB_ENDDRAG
04191049TB_COMMANDTOINDEX
04191049TBM_GETTHUMBRECT
04191049TTM_GETMAXTIPWIDTH
041a1050RB_DRAGMOVE
041a1050TBM_GETCHANNELRECT
041a1050TB_SAVERESTOREA
041a1050TTM_SETMARGIN
041b1051RB_GETBARHEIGHT
041b1051TB_CUSTOMIZE
041b1051TBM_SETTHUMBLENGTH
041b1051TTM_GETMARGIN
041c1052RB_GETBANDINFOW
041c1052TB_ADDSTRINGA
041c1052TBM_GETTHUMBLENGTH
041c1052TTM_POP
041d1053RB_GETBANDINFOA
041d1053TB_GETITEMRECT
041d1053TBM_SETTOOLTIPS
041d1053TTM_UPDATE
041e1054RB_MINIMIZEBAND
041e1054TB_BUTTONSTRUCTSIZE
041e1054TBM_GETTOOLTIPS
041e1054TTM_GETBUBBLESIZE
041f1055RB_MAXIMIZEBAND
041f1055TBM_SETTIPSIDE
041f1055TB_SETBUTTONSIZE
041f1055TTM_ADJUSTRECT
04201056TBM_SETBUDDY
04201056TB_SETBITMAPSIZE
04201056TTM_SETTITLEA
04211057MSG_FTS_JUMP_VA
04211057TB_AUTOSIZE
04211057TBM_GETBUDDY
04211057TTM_SETTITLEW
04221058RB_GETBANDBORDERS
04231059MSG_FTS_JUMP_QWORD
04231059RB_SHOWBAND
04231059TB_GETTOOLTIPS
04241060MSG_REINDEX_REQUEST
04241060TB_SETTOOLTIPS
04251061MSG_FTS_WHERE_IS_IT
04251061RB_SETPALETTE
04251061TB_SETPARENT
04261062RB_GETPALETTE
04271063RB_MOVEBAND
04271063TB_SETROWS
04281064TB_GETROWS
04291065TB_GETBITMAPFLAGS
042a1066TB_SETCMDID
042b1067RB_PUSHCHEVRON
042b1067TB_CHANGEBITMAP
042c1068TB_GETBITMAP
042d1069MSG_GET_DEFFONT
042d1069TB_GETBUTTONTEXTA
042e1070TB_REPLACEBITMAP
042f1071TB_SETINDENT
04301072TB_SETIMAGELIST
04311073TB_GETIMAGELIST
04321074TB_LOADIMAGES
04321074EM_CANPASTE
04321074TTM_ADDTOOLW
04331075EM_DISPLAYBAND
04331075TB_GETRECT
04331075TTM_DELTOOLW
04341076EM_EXGETSEL
04341076TB_SETHOTIMAGELIST
04341076TTM_NEWTOOLRECTW
04351077EM_EXLIMITTEXT
04351077TB_GETHOTIMAGELIST
04351077TTM_GETTOOLINFOW
04361078EM_EXLINEFROMCHAR
04361078TB_SETDISABLEDIMAGELIST
04361078TTM_SETTOOLINFOW
04371079EM_EXSETSEL
04371079TB_GETDISABLEDIMAGELIST
04371079TTM_HITTESTW
04381080EM_FINDTEXT
04381080TB_SETSTYLE
04381080TTM_GETTEXTW
04391081EM_FORMATRANGE
04391081TB_GETSTYLE
04391081TTM_UPDATETIPTEXTW
043a1082EM_GETCHARFORMAT
043a1082TB_GETBUTTONSIZE
043a1082TTM_ENUMTOOLSW
043b1083EM_GETEVENTMASK
043b1083TB_SETBUTTONWIDTH
043b1083TTM_GETCURRENTTOOLW
043c1084EM_GETOLEINTERFACE
043c1084TB_SETMAXTEXTROWS
043d1085EM_GETPARAFORMAT
043d1085TB_GETTEXTROWS
043e1086EM_GETSELTEXT
043e1086TB_GETOBJECT
043f1087EM_HIDESELECTION
043f1087TB_GETBUTTONINFOW
04401088EM_PASTESPECIAL
04401088TB_SETBUTTONINFOW
04411089EM_REQUESTRESIZE
04411089TB_GETBUTTONINFOA
04421090EM_SELECTIONTYPE
04421090TB_SETBUTTONINFOA
04431091EM_SETBKGNDCOLOR
04431091TB_INSERTBUTTONW
04441092EM_SETCHARFORMAT
04441092TB_ADDBUTTONSW
04451093EM_SETEVENTMASK
04451093TB_HITTEST
04461094EM_SETOLECALLBACK
04461094TB_SETDRAWTEXTFLAGS
04471095EM_SETPARAFORMAT
04471095TB_GETHOTITEM
04481096EM_SETTARGETDEVICE
04481096TB_SETHOTITEM
04491097EM_STREAMIN
04491097TB_SETANCHORHIGHLIGHT
044a1098EM_STREAMOUT
044a1098TB_GETANCHORHIGHLIGHT
044b1099EM_GETTEXTRANGE
044b1099TB_GETBUTTONTEXTW
044c1100EM_FINDWORDBREAK
044c1100TB_SAVERESTOREW
044d1101EM_SETOPTIONS
044d1101TB_ADDSTRINGW
044e1102EM_GETOPTIONS
044e1102TB_MAPACCELERATORA
044f1103EM_FINDTEXTEX
044f1103TB_GETINSERTMARK
04501104EM_GETWORDBREAKPROCEX
04501104TB_SETINSERTMARK
04511105EM_SETWORDBREAKPROCEX
04511105TB_INSERTMARKHITTEST
04521106EM_SETUNDOLIMIT
04521106TB_MOVEBUTTON
04531107TB_GETMAXSIZE
04541108EM_REDO
04541108TB_SETEXTENDEDSTYLE
04551109EM_CANREDO
04551109TB_GETEXTENDEDSTYLE
04561110EM_GETUNDONAME
04561110TB_GETPADDING
04571111EM_GETREDONAME
04571111TB_SETPADDING
04581112EM_STOPGROUPTYPING
04581112TB_SETINSERTMARKCOLOR
04591113EM_SETTEXTMODE
04591113TB_GETINSERTMARKCOLOR
045a1114EM_GETTEXTMODE
045a1114TB_MAPACCELERATORW
045b1115EM_AUTOURLDETECT
045b1115TB_GETSTRINGW
045c1116EM_GETAUTOURLDETECT
045c1116TB_GETSTRINGA
045d1117EM_SETPALETTE
045e1118EM_GETTEXTEX
045f1119EM_GETTEXTLENGTHEX
04601120EM_SHOWSCROLLBAR
04611121EM_SETTEXTEX
04631123TAPI_REPLY
04641124ACM_OPENA
04641124BFFM_SETSTATUSTEXTA
04641124CDM_FIRST
04641124CDM_GETSPEC
04641124EM_SETPUNCTUATION
04641124IPM_CLEARADDRESS
04641124WM_CAP_UNICODE_START
04651125ACM_PLAY
04651125BFFM_ENABLEOK
04651125CDM_GETFILEPATH
04651125EM_GETPUNCTUATION
04651125IPM_SETADDRESS
04651125PSM_SETCURSEL
04651125UDM_SETRANGE
04651125WM_CHOOSEFONT_SETLOGFONT
04661126ACM_STOP
04661126BFFM_SETSELECTIONA
04661126CDM_GETFOLDERPATH
04661126EM_SETWORDWRAPMODE
04661126IPM_GETADDRESS
04661126PSM_REMOVEPAGE
04661126UDM_GETRANGE
04661126WM_CAP_SET_CALLBACK_ERRORW
04661126WM_CHOOSEFONT_SETFLAGS
04671127ACM_OPENW
04671127BFFM_SETSELECTIONW
04671127CDM_GETFOLDERIDLIST
04671127EM_GETWORDWRAPMODE
04671127IPM_SETRANGE
04671127PSM_ADDPAGE
04671127UDM_SETPOS
04671127WM_CAP_SET_CALLBACK_STATUSW
04681128BFFM_SETSTATUSTEXTW
04681128CDM_SETCONTROLTEXT
04681128EM_SETIMECOLOR
04681128IPM_SETFOCUS
04681128PSM_CHANGED
04681128UDM_GETPOS
04691129CDM_HIDECONTROL
04691129EM_GETIMECOLOR
04691129IPM_ISBLANK
04691129PSM_RESTARTWINDOWS
04691129UDM_SETBUDDY
046a1130CDM_SETDEFEXT
046a1130EM_SETIMEOPTIONS
046a1130PSM_REBOOTSYSTEM
046a1130UDM_GETBUDDY
046b1131EM_GETIMEOPTIONS
046b1131PSM_CANCELTOCLOSE
046b1131UDM_SETACCEL
046c1132EM_CONVPOSITION
046c1132EM_CONVPOSITION
046c1132PSM_QUERYSIBLINGS
046c1132UDM_GETACCEL
046d1133MCIWNDM_GETZOOM
046d1133PSM_UNCHANGED
046d1133UDM_SETBASE
046e1134PSM_APPLY
046e1134UDM_GETBASE
046f1135PSM_SETTITLEA
046f1135UDM_SETRANGE32
04701136PSM_SETWIZBUTTONS
04701136UDM_GETRANGE32
04701136WM_CAP_DRIVER_GET_NAMEW
04711137PSM_PRESSBUTTON
04711137UDM_SETPOS32
04711137WM_CAP_DRIVER_GET_VERSIONW
04721138PSM_SETCURSELID
04721138UDM_GETPOS32
04731139PSM_SETFINISHTEXTA
04741140PSM_GETTABCONTROL
04751141PSM_ISDIALOGMESSAGE
04761142MCIWNDM_REALIZE
04761142PSM_GETCURRENTPAGEHWND
04771143MCIWNDM_SETTIMEFORMATA
04771143PSM_INSERTPAGE
04781144EM_SETLANGOPTIONS
04781144MCIWNDM_GETTIMEFORMATA
04781144PSM_SETTITLEW
04781144WM_CAP_FILE_SET_CAPTURE_FILEW
04791145EM_GETLANGOPTIONS
04791145MCIWNDM_VALIDATEMEDIA
04791145PSM_SETFINISHTEXTW
04791145WM_CAP_FILE_GET_CAPTURE_FILEW
047a1146EM_GETIMECOMPMODE
047b1147EM_FINDTEXTW
047b1147MCIWNDM_PLAYTO
047b1147WM_CAP_FILE_SAVEASW
047c1148EM_FINDTEXTEXW
047c1148MCIWNDM_GETFILENAMEA
047d1149EM_RECONVERSION
047d1149MCIWNDM_GETDEVICEA
047d1149PSM_SETHEADERTITLEA
047d1149WM_CAP_FILE_SAVEDIBW
047e1150EM_SETIMEMODEBIAS
047e1150MCIWNDM_GETPALETTE
047e1150PSM_SETHEADERTITLEW
047f1151EM_GETIMEMODEBIAS
047f1151MCIWNDM_SETPALETTE
047f1151PSM_SETHEADERSUBTITLEA
04801152MCIWNDM_GETERRORA
04801152PSM_SETHEADERSUBTITLEW
04811153PSM_HWNDTOINDEX
04821154PSM_INDEXTOHWND
04831155MCIWNDM_SETINACTIVETIMER
04831155PSM_PAGETOINDEX
04841156PSM_INDEXTOPAGE
04851157DL_BEGINDRAG
04851157MCIWNDM_GETINACTIVETIMER
04851157PSM_IDTOINDEX
04861158DL_DRAGGING
04861158PSM_INDEXTOID
04871159DL_DROPPED
04871159PSM_GETRESULT
04881160DL_CANCELDRAG
04881160PSM_RECALCPAGESIZES
048c1164MCIWNDM_GET_SOURCE
048d1165MCIWNDM_PUT_SOURCE
048e1166MCIWNDM_GET_DEST
048f1167MCIWNDM_PUT_DEST
04901168MCIWNDM_CAN_PLAY
04911169MCIWNDM_CAN_WINDOW
04921170MCIWNDM_CAN_RECORD
04931171MCIWNDM_CAN_SAVE
04941172MCIWNDM_CAN_EJECT
04951173MCIWNDM_CAN_CONFIG
04961174IE_GETINK
04961174IE_MSGFIRST
04961174MCIWNDM_PALETTEKICK
04971175IE_SETINK
04981176IE_GETPENTIP
04991177IE_SETPENTIP
049a1178IE_GETERASERTIP
049b1179IE_SETERASERTIP
049c1180IE_GETBKGND
049d1181IE_SETBKGND
049e1182IE_GETGRIDORIGIN
049f1183IE_SETGRIDORIGIN
04a01184IE_GETGRIDPEN
04a11185IE_SETGRIDPEN
04a21186IE_GETGRIDSIZE
04a31187IE_SETGRIDSIZE
04a41188IE_GETMODE
04a51189IE_SETMODE
04a61190IE_GETINKRECT
04a61190WM_CAP_SET_MCI_DEVICEW
04a71191WM_CAP_GET_MCI_DEVICEW
04b41204WM_CAP_PAL_OPENW
04b51205WM_CAP_PAL_SAVEW
04b81208IE_GETAPPDATA
04b91209IE_SETAPPDATA
04ba1210IE_GETDRAWOPTS
04bb1211IE_SETDRAWOPTS
04bc1212IE_GETFORMAT
04bd1213IE_SETFORMAT
04be1214IE_GETINKINPUT
04bf1215IE_SETINKINPUT
04c01216IE_GETNOTIFY
04c11217IE_SETNOTIFY
04c21218IE_GETRECOG
04c31219IE_SETRECOG
04c41220IE_GETSECURITY
04c51221IE_SETSECURITY
04c61222IE_GETSEL
04c71223IE_SETSEL
04c81224CDM_LAST
04c81224EM_SETBIDIOPTIONS
04c81224IE_DOCOMMAND
04c81224MCIWNDM_NOTIFYMODE
04c91225EM_GETBIDIOPTIONS
04c91225IE_GETCOMMAND
04ca1226EM_SETTYPOGRAPHYOPTIONS
04ca1226IE_GETCOUNT
04cb1227EM_GETTYPOGRAPHYOPTIONS
04cb1227IE_GETGESTURE
04cb1227MCIWNDM_NOTIFYMEDIA
04cc1228EM_SETEDITSTYLE
04cc1228IE_GETMENU
04cd1229EM_GETEDITSTYLE
04cd1229IE_GETPAINTDC
04cd1229MCIWNDM_NOTIFYERROR
04ce1230IE_GETPDEVENT
04cf1231IE_GETSELCOUNT
04d01232IE_GETSELITEMS
04d11233IE_GETSTYLE
04db1243MCIWNDM_SETTIMEFORMATW
04dc1244EM_OUTLINE
04dc1244EM_OUTLINE
04dc1244MCIWNDM_GETTIMEFORMATW
04dd1245EM_GETSCROLLPOS
04dd1245EM_GETSCROLLPOS
04de1246EM_SETSCROLLPOS
04de1246EM_SETSCROLLPOS
04df1247EM_SETFONTSIZE
04df1247EM_SETFONTSIZE
04e01248EM_GETZOOM
04e01248MCIWNDM_GETFILENAMEW
04e11249EM_SETZOOM
04e11249MCIWNDM_GETDEVICEW
04e21250EM_GETVIEWKIND
04e31251EM_SETVIEWKIND
04e41252EM_GETPAGE
04e41252MCIWNDM_GETERRORW
04e51253EM_SETPAGE
04e61254EM_GETHYPHENATEINFO
04e71255EM_SETHYPHENATEINFO
04eb1259EM_GETPAGEROTATE
04ec1260EM_SETPAGEROTATE
04ed1261EM_GETCTFMODEBIAS
04ee1262EM_SETCTFMODEBIAS
04f01264EM_GETCTFOPENSTATUS
04f11265EM_SETCTFOPENSTATUS
04f21266EM_GETIMECOMPTEXT
04f31267EM_ISIME
04f41268EM_GETIMEPROPERTY
050d1293EM_GETQUERYRTFOBJ
050e1294EM_SETQUERYRTFOBJ
06001536FM_GETFOCUS
06011537FM_GETDRIVEINFOA
06021538FM_GETSELCOUNT
06031539FM_GETSELCOUNTLFN
06041540FM_GETFILESELA
06051541FM_GETFILESELLFNA
06061542FM_REFRESH_WINDOWS
06071543FM_RELOAD_EXTENSIONS
06111553FM_GETDRIVEINFOW
06141556FM_GETFILESELW
06151557FM_GETFILESELLFNW
06591625WLX_WM_SAS
07e82024SM_GETSELCOUNT
07e82024UM_GETSELCOUNT
07e82024WM_CPL_LAUNCH
07e92025SM_GETSERVERSELA
07e92025UM_GETUSERSELA
07e92025WM_CPL_LAUNCHED
07ea2026SM_GETSERVERSELW
07ea2026UM_GETUSERSELW
07eb2027SM_GETCURFOCUSA
07eb2027UM_GETGROUPSELA
07ec2028SM_GETCURFOCUSW
07ec2028UM_GETGROUPSELW
07ed2029SM_GETOPTIONS
07ed2029UM_GETCURFOCUSA
07ee2030UM_GETCURFOCUSW
07ef2031UM_GETOPTIONS
07f02032UM_GETOPTIONS2
10004096LVM_FIRST
10004096LVM_GETBKCOLOR
10014097LVM_SETBKCOLOR
10024098LVM_GETIMAGELIST
10034099LVM_SETIMAGELIST
10044100LVM_GETITEMCOUNT
10054101LVM_GETITEMA
10064102LVM_SETITEMA
10074103LVM_INSERTITEMA
10084104LVM_DELETEITEM
10094105LVM_DELETEALLITEMS
100a4106LVM_GETCALLBACKMASK
100b4107LVM_SETCALLBACKMASK
100c4108LVM_GETNEXTITEM
100d4109LVM_FINDITEMA
100e4110LVM_GETITEMRECT
100f4111LVM_SETITEMPOSITION
10104112LVM_GETITEMPOSITION
10114113LVM_GETSTRINGWIDTHA
10124114LVM_HITTEST
10134115LVM_ENSUREVISIBLE
10144116LVM_SCROLL
10154117LVM_REDRAWITEMS
10164118LVM_ARRANGE
10174119LVM_EDITLABELA
10184120LVM_GETEDITCONTROL
10194121LVM_GETCOLUMNA
101a4122LVM_SETCOLUMNA
101b4123LVM_INSERTCOLUMNA
101c4124LVM_DELETECOLUMN
101d4125LVM_GETCOLUMNWIDTH
101e4126LVM_SETCOLUMNWIDTH
101f4127LVM_GETHEADER
10214129LVM_CREATEDRAGIMAGE
10224130LVM_GETVIEWRECT
10234131LVM_GETTEXTCOLOR
10244132LVM_SETTEXTCOLOR
10254133LVM_GETTEXTBKCOLOR
10264134LVM_SETTEXTBKCOLOR
10274135LVM_GETTOPINDEX
10284136LVM_GETCOUNTPERPAGE
10294137LVM_GETORIGIN
102a4138LVM_UPDATE
102b4139LVM_SETITEMSTATE
102c4140LVM_GETITEMSTATE
102d4141LVM_GETITEMTEXTA
102e4142LVM_SETITEMTEXTA
102f4143LVM_SETITEMCOUNT
10304144LVM_SORTITEMS
10314145LVM_SETITEMPOSITION32
10324146LVM_GETSELECTEDCOUNT
10334147LVM_GETITEMSPACING
10344148LVM_GETISEARCHSTRINGA
10354149LVM_SETICONSPACING
10364150LVM_SETEXTENDEDLISTVIEWSTYLE
10374151LVM_GETEXTENDEDLISTVIEWSTYLE
10384152LVM_GETSUBITEMRECT
10394153LVM_SUBITEMHITTEST
103a4154LVM_SETCOLUMNORDERARRAY
103b4155LVM_GETCOLUMNORDERARRAY
103c4156LVM_SETHOTITEM
103d4157LVM_GETHOTITEM
103e4158LVM_SETHOTCURSOR
103f4159LVM_GETHOTCURSOR
10404160LVM_APPROXIMATEVIEWRECT
10414161LVM_SETWORKAREAS
10424162LVM_GETSELECTIONMARK
10434163LVM_SETSELECTIONMARK
10444164LVM_SETBKIMAGEA
10454165LVM_GETBKIMAGEA
10464166LVM_GETWORKAREAS
10474167LVM_SETHOVERTIME
10484168LVM_GETHOVERTIME
10494169LVM_GETNUMBEROFWORKAREAS
104a4170LVM_SETTOOLTIPS
104b4171LVM_GETITEMW
104c4172LVM_SETITEMW
104d4173LVM_INSERTITEMW
104e4174LVM_GETTOOLTIPS
10534179LVM_FINDITEMW
10574183LVM_GETSTRINGWIDTHW
105f4191LVM_GETCOLUMNW
10604192LVM_SETCOLUMNW
10614193LVM_INSERTCOLUMNW
10734211LVM_GETITEMTEXTW
10744212LVM_SETITEMTEXTW
10754213LVM_GETISEARCHSTRINGW
10764214LVM_EDITLABELW
108b4235LVM_GETBKIMAGEW
108c4236LVM_SETSELECTEDCOLUMN
108d4237LVM_SETTILEWIDTH
108e4238LVM_SETVIEW
108f4239LVM_GETVIEW
10914241LVM_INSERTGROUP
10934243LVM_SETGROUPINFO
10954245LVM_GETGROUPINFO
10964246LVM_REMOVEGROUP
10974247LVM_MOVEGROUP
109a4250LVM_MOVEITEMTOGROUP
109b4251LVM_SETGROUPMETRICS
109c4252LVM_GETGROUPMETRICS
109d4253LVM_ENABLEGROUPVIEW
109e4254LVM_SORTGROUPS
109f4255LVM_INSERTGROUPSORTED
10a04256LVM_REMOVEALLGROUPS
10a14257LVM_HASGROUP
10a24258LVM_SETTILEVIEWINFO
10a34259LVM_GETTILEVIEWINFO
10a44260LVM_SETTILEINFO
10a54261LVM_GETTILEINFO
10a64262LVM_SETINSERTMARK
10a74263LVM_GETINSERTMARK
10a84264LVM_INSERTMARKHITTEST
10a94265LVM_GETINSERTMARKRECT
10aa4266LVM_SETINSERTMARKCOLOR
10ab4267LVM_GETINSERTMARKCOLOR
10ad4269LVM_SETINFOTIP
10ae4270LVM_GETSELECTEDCOLUMN
10af4271LVM_ISGROUPVIEWENABLED
10b04272LVM_GETOUTLINECOLOR
10b14273LVM_SETOUTLINECOLOR
10b34275LVM_CANCELEDITLABEL
10b44276LVM_MAPINDEXTOID
10b54277LVM_MAPIDTOINDEX
10b64278LVM_ISITEMVISIBLE
20008192OCM__BASE
20058197LVM_SETUNICODEFORMAT
20068198LVM_GETUNICODEFORMAT
20198217OCM_CTLCOLOR
202b8235OCM_DRAWITEM
202c8236OCM_MEASUREITEM
202d8237OCM_DELETEITEM
202e8238OCM_VKEYTOITEM
202f8239OCM_CHARTOITEM
20398249OCM_COMPAREITEM
204e8270OCM_NOTIFY
21118465OCM_COMMAND
21148468OCM_HSCROLL
21158469OCM_VSCROLL
21328498OCM_CTLCOLORMSGBOX
21338499OCM_CTLCOLOREDIT
21348500OCM_CTLCOLORLISTBOX
21358501OCM_CTLCOLORBTN
21368502OCM_CTLCOLORDLG
21378503OCM_CTLCOLORSCROLLBAR
21388504OCM_CTLCOLORSTATIC
22108720OCM_PARENTNOTIFY
800032768WM_APP
cccd52429WM_RASDIALEVENT


參考來源:
https://wiki.winehq.org/List_Of_Windows_Messages
https://www.appeon.com/support/documents/appeon_online_help/pb2017r2/powerscript_reference/ch10s535.html
https://wenku.baidu.com/view/a9e114d6b14e852458fb5730.html
https://msdn.microsoft.com/en-us/library/windows/desktop/bb787577(v=vs.85).aspx


在Google上如果要搜尋這些ID的定義,利用關鍵字 Notifications(通知)
例如這裡要找 Scroll 控制用 Notifications 就如下:



然後就去找 微軟MSDN(Windows) 相關網頁就很方便了。

致於 Message ID 有的會帶 參數 lparam(LOWORD) , wparam(HIWORD) 在微軟官方網站真的很難找甚至可以說找不到,因為微軟都直接使用定義好的名詞 ,例如:SB_THUMBPOSITION 或 SB_THUMBTRACK 等等...

在非微軟開發工具下真的很不方便,此時可以透過像是下面的第三方網站提供的資訊,可以很方便去查詢:
例如: http://www.pinvoke.net/default.aspx/Enums/ScrollBarCommands.html?diff=y
來查 VSCROLL 的傳遞參數...


找到實際數值了...




留言

Unknown寫道…
感謝前輩的詳細說明,真的是受益良多
WILDOX寫道…
Re: mawping sheu <1821937024657415389>

不客氣囉

這個網誌中的熱門文章

【研究】列印的條碼為什麼很難刷(掃描)

統一發票列印小程式

C# 使用 Process.Start 執行外部程式