Scrollbar madness
- From: Liska Station <msnewsJUNKFILTER@xxxxxxxxxxxxxx>
- Date: Mon, 30 Apr 2007 06:49:32 -0700
Another fun challenge!
Okay, I'm trying to add a GUI to a program that a client specifically
requested. Here's the deal though - it's going to have a lot of
dynamically moving elements (...yay.)
Here's the thing. I'm trying to get the scrollbars to cooperate, and they
won't.
For example, if I put a container class on the form (with scrollbars
enabled) and then put a command button in the container, I can then put the
following code in the click button's CLICK event (bear in mind this is a
test to simulate what I want it to do when there's LOTS of controls inside
the main container class):
this.top = this.top + 500 && takes it off the bottom of the form
IF this.Parent.Height < (this.Top + this.Height) && the container isn't big
enough
this.Parent.Height = this.Top + this.Height && expand the parent
ENDIF
**Code for horizontal omitted
this.Parent.Refresh && doesn't help
thisform.Refresh
Well, the CONTAINER gets bigger, and although they act a tad werid, the
scrollbars seem to work, kinda sorta, but the container itself doesn't
refresh, and I can't see the command button in it until I click it again
(meaning I have to do a little scavenger-hunt type click-around until I
find it). Also the form screen will randomly go black on me and then skip
back to being grey during some iterations of the code. This was when I was
getting close to command1.TOP=70000 or so, and I'm guessing that probably
shouldn't be a real surprise.
Anyone have any idea why this happens and how to solve? I'm not really
seeing in the vfp9 docs anything that might help. I know in VFP 6/7 there
was a limit on scroll size (double screen resolution), but that doesn't
appear to be the case here, as I've gotten it to somewhere around HEIGHT =
20000 to 25000 by simply assigning a huge value to "Top" to random items on
the form, and higher using my click button. If I could just get the
container the button is in to properly refresh after it goes offscreen,
then life would be grand.
Any ideas?
Thanks!
-LS
.
- Follow-Ups:
- Re: Scrollbar sanity
- From: Liska Station
- Re: Scrollbar sanity
- Prev by Date: Anyone tried running VFP9 in Macbook Pro using Bootcamp?
- Next by Date: Re: Re-Post: Project Path References
- Previous by thread: Anyone tried running VFP9 in Macbook Pro using Bootcamp?
- Next by thread: Re: Scrollbar sanity
- Index(es):