What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Messenger Plus! for Live Messenger » Scripting » slidercontrol in vertical

slidercontrol in vertical
Author: Message:
Dennis Mike
Junior Member
**

Avatar

Posts: 59
Reputation: 2
34 / Male / –
Joined: Jan 2007
O.P. slidercontrol in vertical
why slidercontrol in vertical not produce the event OnWindowidEvent_MessageNotification?
if the slidercontrol in horizontal yes produce 
02-27-2007 04:10 AM
Profile PM Web Find Quote Report
Felu
Veteran Member
*****


Posts: 2223
Reputation: 72
30 / Male / Flag
Joined: Apr 2006
Status: Away
RE: slidercontrol in vertical
Try using [Library] SliderControl?
02-27-2007 04:34 AM
Profile E-Mail PM Web Find Quote Report
deAd
Scripting Contest Winner
*****

Avatar

Posts: 1060
Reputation: 28
– / Male / Flag
Joined: Jan 2006
RE: RE: slidercontrol in vertical
quote:
Originally posted by Felu
Try using [Library] SliderControl?

That shouldn't be necessary.

What message are you looking for?

For horizontal scrollbars, you'll want to look for WM_HSCROLL. However, since your scrollbar is vertical, you'll want to register a notification for WM_VSCROLL. However, you will need to do further processing on wParam to find the specific action being executed on the scrollbar.

This code is not tested but should probably work (it does not check specifically what is happening with the scrollbar):
code:
var WM_HSCROLL = 0x0114;
var WM_VSCROLL = 0x0115;

function OnEvent_Initialize(bMessengerStart){
     // Create a window that theoretically contains both a horizontal and vertical scrollbar.
     var pWnd = MsgPlus.CreateWnd("ScrollbarExample.xml", "ScrollbarWnd");
     // Register message notifications for each type of scrollbar
     pWnd.RegisterMessageNotification(WM_HSCROLL);
     pWnd.RegisterMessageNotification(WM_VSCROLL);
}

// An event for the window
function OnScrollbarWndEvent_MessageNotification(pWnd, nMessage, wParam, lParam){
     // check which message it is
     switch(nMessage){
          case WM_HSCROLL: // if it is the horizontal one
               Debug.Trace("Horizontal scrollbar changed!");
               break; // so it doesn't go on
          case WM_VSCROLL: // if it is the vertical one
               Debug.Trace("Vertical scrollbar changed!");
               break; // so it doesn't go on
     }
     // let Windows process the message like normal
     return -1;
}

This post was edited on 02-27-2007 at 04:56 AM by deAd.
02-27-2007 04:48 AM
Profile PM Find Quote Report
deAd
Scripting Contest Winner
*****

Avatar

Posts: 1060
Reputation: 28
– / Male / Flag
Joined: Jan 2006
RE: RE: slidercontrol in vertical
quote:
Originally posted by Dennis Mike
watch the Attachment

What attachment?

This post was edited on 02-27-2007 at 05:02 AM by deAd.
02-27-2007 05:01 AM
Profile PM Find Quote Report
Dennis Mike
Junior Member
**

Avatar

Posts: 59
Reputation: 2
34 / Male / –
Joined: Jan 2007
O.P. RE: slidercontrol in vertical
thanks by WM_VSCROLL, i had used only WM_HSCROL
02-27-2007 05:32 AM
Profile PM Web Find Quote Report
« Next Oldest Return to Top Next Newest »


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On