A customer reported a problem and I can see what is happening but I don’t know why.
I have a WebContainer on my window. The actual size of the container may be larger than what I have allocated for it on the window. So then the WebContainer scrolls. In the ContentsScrolled event I set some properties of the Container to the x and y variables in the event. I use these scroll positions to calculate some positions of other controls. However, this event is never firing! The properties I am using to store the scroll position never get updated. And this is causing the problem my customer reported.
Am I doing something wrong? When I scroll the WebContainer, shouldn’t the ContentsScrolled event fire?
I tried trapping the MouseMove event and that doesn’t fire either.
OK. I must be the only person who is attempting to use the ContentsScrolled event on a WebContainer. I’ll have to figure this out myself then. I’ll file a bug report if I figure out is in indeed a bug. Problem is I’m not entirely sure if what I am doing is supposed to trigger that event. I think so but I’m not positive. That’s why it would be helpful if others who are using this event could say “yeah - it works.” Oh well…
Actually, it doesn’t fire on a WebContainer placed right on the page either when vertically scrolled. It does fire when you horizontal scroll.
The issue I have is with knowing where to place some other controls when the page is scrolled. I don’t know if you remember the menu you helped me create using a listbox. That works great, but I am using the scroll position to calculate the position of the menu. But I’ll have to look at doing it another way.