473,320 Members | 2,180 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

c# - listbox onScroll event

Can anyone tell me how to fire and use a listBox vertical onScroll event.
The
language I am using is C# in a windows forms application

thanks
Oct 27 '05 #1
1 2976
Hi John,
ListBox doesnot provide a interface for your to manipulate the scrollbar
directly. As a workaround, you can try sending WM_VSCROLL message via
PInvoke. For
example:
Class Win32
{
[DllImport("User32.Dll")]
public static extern bool SendMessage(IntPtr hWnd,int Msg,int
wParam,int lParam);
public const int WM_VSCROLL = 0x0115;
public const int SB_LINEDOWN = 1;

}
Win32.SendMessage(listBox1.Handle,Win32.WM_VSCROLL ,Win32.SB_LINEDOWN,0);

Hope this helps.
Regards,

Luke
Oct 28 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: viza | last post by:
Hi! I use the onscroll event to make something like the CSS position:fixed; for MSIE. In MSIE/5.5, before a function is assigned to the event handler, it has the value null. In Opera, it is...
1
by: Mark Szlazak | last post by:
Is there a way to detect if an textarea onscroll event is working in Firefox (or Mozilla). I know that there is an onscroll event bubbling bug with current vesions of these browsers so I want to...
2
by: lorinho | last post by:
Alright, I'm stumped. Per this article from Microsoft I should be able to capture the onscroll event for an iframe but for some reason it doesn't seem to be working for me... ...
1
by: Simon Wigzell | last post by:
Firefox has strange behaviour with onscroll. I have a sample page here: http://www.dynamicwebsitesystems.com/ScrollTest.htm If I make this the startup page for the firefox browser or launch it...
1
by: John Keers | last post by:
Can anyone tell me how to fire and use a listBox vertical onScroll event. The language I am using is C# in a windows forms application thanks
0
by: Jocker | last post by:
Hi Group I'm writing an Internet Explorer plugin. Everything works well, except when I try to handle the onscroll event....
0
by: Jocker | last post by:
I'll try reposting this message with the hope someone can help me with this issue. PS: is this the right newsgroup for this question? --- Hi Group I'm writing an Internet Explorer plugin....
2
by: Sam | last post by:
While attempting to get my floating toolbar to work in ASP.NET 2.0, I noticed that the onscroll event is not firing. I've specified this on the BODY tag, as always. After some testing, I...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.