Quantcast
Channel: VBForums - Visual Basic 6 and Earlier
Viewing all articles
Browse latest Browse all 21088

Statusbar.Top value gives false return value when Form is maximized

$
0
0
If I manually resize the Form then Statusbar.Top always returns the correct value as the Form is made bigger or smaller.

However, if I maximize the Form the Statusbar.Top value stays the same value it had when the Form first loaded up. Then when I click the max button to restore it to it's original size the .Top value reads a totally different value

I ran a test showing the .Top value of the Statusbar on a label.

When the Form is first loaded up the .Top value returns 298. This is correct

Now I click on the max button and fully maximize the Form. The .Top value did not change; it stayed at 298

Now I click on the max button again to restore the Form to it's original size and now the .Top value shows 707.

The Statusbar itself stays at the bottom as it is supposed to do; only it's .Top value is giving false return values which causes a problem as I use this value to position a picturebox control on top of the statusbar. When the Form is max'd or return to normal the picturebox is totally out of position because it is supposed to be positioned at Statusbar.Top +5

Viewing all articles
Browse latest Browse all 21088

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>