Vista cuts bottom of my form  
Author Message
petedavo





PostPosted: Sat Jun 30 02:22:57 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form

Hello,
User complains, that Vista cuts bottom of my app GUI and he cannot
accress controls placed in there.
In my Vista, only the edge is cut and I can access the controls at the
bottom.
What is the cause of that problem and how to redesign GUI ?
Thanks,
Jack

Visual Studio328  
 
 
Rick





PostPosted: Sat Jun 30 02:22:57 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form > User complains, that Vista cuts bottom of my app GUI and he cannot
> accress controls placed in there.
> In my Vista, only the edge is cut and I can access the controls at the
> bottom.
> What is the cause of that problem and how to redesign GUI ?

I'd be willing to bet your user has his font settings at something other
than the standard 96 dots per inch. You user can check by right-clicking on
an empty spot on the Desktop and selecting Properties from the popup menu
that appears. On the left side of the dialog box that comes up (under the
panel with "Tasks" listed at the top) there is a hyperlink with the caption
"Adjust font size (DPI)"... have the user click it and tell you what setting
is shown.

Rick

 
 
Mike





PostPosted: Sat Jun 30 04:12:19 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form


> User complains, that Vista cuts bottom of my app GUI
> and he cannot accress controls placed in there. In my
> Vista, only the edge is cut and I can access the controls
> at the bottom.

If anything at all is cut (edge or bottom) then you're doing something
wrong. Is this Form run maximized or is it set to a specified size? If it is
set to a specified size then are you checking in code at run time that the
available screen area is large enough to accommodate that size, and are you
adjusting both the size of the Form and the position of its Controls if
there is not enough room? And if it is run maximized, are you checking
*after it has loaded and resized itself* what size that actually is on the
machine on which it is currently running. In both cases (after resizing the
Form so that it fits on the display in the case of a small Form and after
Windows has resized it in the case of a maximized Form) you need to check
the Form's client area (ScaleWidth and ScaleHeight) and you then need to
position all your controls in accordance with their own Width and Height
properties and taking into account your desired layout so that everything
fits. You need to *always* do these things, in *all* of your programs,
regardless of whether the code is running in Win98 or WinXP or Vista or
anything else.

Mike



 
 
Bob





PostPosted: Sat Jun 30 08:25:53 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form

> Hello,
> User complains, that Vista cuts bottom of my app GUI and he cannot
> accress controls placed in there.
> In my Vista, only the edge is cut and I can access the controls at the
> bottom.
> What is the cause of that problem and how to redesign GUI ?

If none of the other respones solves the problem then there is an issue in
VB that can cause a strip of the form to not be displayed. I don't remember
how to cause it but it has something to do with VB not allowing room for the
menu bar so while the menu is shown OK at the top a strip at the bottom the
same height as the menu is missing.

The workaround is to open the code in the IDE, open the form in question so
that you can see it and then compile. If you compile with the form designer
window closed it can sometimes do it wrong.

I've had this happen on at least Win2K and possibly Win9x systems although
it's been a while since I last saw it

 
 
Bob





PostPosted: Sat Jun 30 08:46:54 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form



>> Hello,
>> User complains, that Vista cuts bottom of my app GUI and he cannot
>> accress controls placed in there.
>> In my Vista, only the edge is cut and I can access the controls at the
>> bottom.
>> What is the cause of that problem and how to redesign GUI ?
>
> If none of the other respones solves the problem then there is an issue in
> VB that can cause a strip of the form to not be displayed. I don't
> remember how to cause it but it has something to do with VB not allowing
> room for the menu bar so while the menu is shown OK at the top a strip at
> the bottom the same height as the menu is missing.
>
> The workaround is to open the code in the IDE, open the form in question
> so that you can see it and then compile. If you compile with the form
> designer window closed it can sometimes do it wrong.
>
> I've had this happen on at least Win2K and possibly Win9x systems although
> it's been a while since I last saw it
>

I found a thread about the problem
http://groups.google.com/group/microsoft.public.vb.general.discussion/browse_thread/thread/aee41ac4fe37ce82/094a56323c8cafd0?lnk=st&q=vb+form+menu+bar+cut+off&rnum=1#094a56323c8cafd0

Unfortunately it reminded me that I only ever saw the problem in the IDE;
compiled apps were fine.
...Nevermind...




 
 
Grand_Poobah





PostPosted: Sat Jun 30 16:39:26 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form Mike:

Have you looked at "ReSize OCX" by Larcome & Young?

GP

--->


>
>> User complains, that Vista cuts bottom of my app GUI
>> and he cannot accress controls placed in there. In my
>> Vista, only the edge is cut and I can access the controls
>> at the bottom.
>
> If anything at all is cut (edge or bottom) then you're doing something
> wrong. Is this Form run maximized or is it set to a specified size? If
> it is set to a specified size then are you checking in code at run time
> that the available screen area is large enough to accommodate that size,
> and are you adjusting both the size of the Form and the position of its
> Controls if there is not enough room? And if it is run maximized, are
> you checking *after it has loaded and resized itself* what size that
> actually is on the machine on which it is currently running. In both
> cases (after resizing the Form so that it fits on the display in the
> case of a small Form and after Windows has resized it in the case of a
> maximized Form) you need to check the Form's client area (ScaleWidth and
> ScaleHeight) and you then need to position all your controls in
> accordance with their own Width and Height properties and taking into
> account your desired layout so that everything fits. You need to
> *always* do these things, in *all* of your programs, regardless of
> whether the code is running in Win98 or WinXP or Vista or anything else.
>
> Mike
>
>
>
 
 
Mike





PostPosted: Sat Jun 30 16:55:51 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form


> Mike:
> Have you looked at "ReSize OCX" by Larcome & Young?

No. I would much sooner write my own resizing code. Besides, there is no
such thing as a resizing control that just works "as is" under all
conditions. It is not actually possible to write such a beast. Show me a
resizing Control that you just drop on a Form and forget it and I'll show
you a VB application on which it fails to work. The only resizing control
that would work for all VB applications is one that allows the user
(programmmer) to edit and modify its functions in lots of different ways,
and if you're going to edit and modify a resizing control you might as well
write it yourself in the first place ;-)

Mike


 
 
Galen





PostPosted: Sat Jun 30 18:56:45 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form




>
>> Mike:
>> Have you looked at "ReSize OCX" by Larcome & Young?
>
> No. I would much sooner write my own resizing code. Besides, there is no
> such thing as a resizing control that just works "as is" under all
> conditions. It is not actually possible to write such a beast. Show me a
> resizing Control that you just drop on a Form and forget it and I'll show
> you a VB application on which it fails to work. The only resizing control
> that would work for all VB applications is one that allows the user
> (programmmer) to edit and modify its functions in lots of different ways,
> and if you're going to edit and modify a resizing control you might as
> well write it yourself in the first place ;-)
>
> Mike
>
>
I use one by Trinitronix that does all of that. Too bad it disappeared
awhile back.

Galen


 
 
Grand_Poobah





PostPosted: Sat Jun 30 19:20:51 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form


>
>> Mike:
>> Have you looked at "ReSize OCX" by Larcome & Young?
>
> No. I would much sooner write my own resizing code. Besides, there is no
> such thing as a resizing control that just works "as is" under all
> conditions. It is not actually possible to write such a beast. Show me a
> resizing Control that you just drop on a Form and forget it and I'll
> show you a VB application on which it fails to work. The only resizing
> control that would work for all VB applications is one that allows the
> user (programmmer) to edit and modify its functions in lots of different
> ways, and if you're going to edit and modify a resizing control you
> might as well write it yourself in the first place ;-)
>
> Mike
>
>

Too bad you're so hard set against this "drop in" control. That's all
you do - drop it in and set two properties - Min Form Width and Min Form
Height. That's it.

I have been using it for almost 8 years now and have yet to find a
control - VB provided or third-party that won't resize when you drag the
borders. If you try to go too small it just refuses to move. Each and
every control on it will resize to match -- fonts will adjust also.

The OCX is provided on the left side of the IDE and all you have to do
is compile your EXE. The VBP file will contain a reference to the OCX.
The OCX will be delivered with your setup program as a run-time OCX
(different from the developer OCX).

Check it out a www.lyoung.com

GP
 
 
Grand_Poobah





PostPosted: Sat Jun 30 19:21:44 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form Galen:

Check out my reply to Mike.

GP

--->




>>
>>> Mike:
>>> Have you looked at "ReSize OCX" by Larcome & Young?
>> No. I would much sooner write my own resizing code. Besides, there is no
>> such thing as a resizing control that just works "as is" under all
>> conditions. It is not actually possible to write such a beast. Show me a
>> resizing Control that you just drop on a Form and forget it and I'll show
>> you a VB application on which it fails to work. The only resizing control
>> that would work for all VB applications is one that allows the user
>> (programmmer) to edit and modify its functions in lots of different ways,
>> and if you're going to edit and modify a resizing control you might as
>> well write it yourself in the first place ;-)
>>
>> Mike
>>
>>
> I use one by Trinitronix that does all of that. Too bad it disappeared
> awhile back.
>
> Galen
>
>
 
 
Steve





PostPosted: Sat Jun 30 20:27:43 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form


>
>
> I have been using it for almost 8 years now and have yet to find a control -
> VB provided or third-party that won't resize when you drag the borders. If
> you try to go too small it just refuses to move. Each and every control on it
> will resize to match -- fonts will adjust also.
>

I guess if that is all you want it do, it would work. When I maximize forms,
like in Outlook or Internet Explorer, or Excel, or the VB code window, etc., I
expect to see more data, not larger type. Font resizing should only occur if the
screen resolution or DPI changes, not if the user just increased the window
size. Single item controls, like checkboxes or labels, the same way. Grids,
multi-line textboxes, and the like should get bigger if the window size
increases, but in a way that displays more data, not a larger font.




 
 
Mike





PostPosted: Sat Jun 30 22:37:41 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form


> I have been using it for almost 8 years now and have yet
> to find a control - VB provided or third-party that won't
> resize when you drag the borders. If you try to go too
> small it just refuses to move. Each and every control on
> it will resize to match -- fonts will adjust also.

But don't you see? That's part of the problem. I can write code that does
what you describe with no trouble at all. But what if you don't want all
your controls to resize? What if you've got certain controls and buttons
that need to remain at a fixed size and a container or text entry box or
something that needs to move appropriately and occupy whatever space is
remaining, or what if you've got a Picture Box that needs to remain at a
fixed pixel size and everything else needs to resize around it, or what if
you've got a combination of both, or what if you've got a text entry area
that needs to "grow" scroll bars and keep the text it contains at the same
size, and what if you've got . . . I could go on for hours!

I can write code that resizes everything in the way you have described with
no trouble at all. But it won't work in any of the above circumstances, and
hundreds more circumstances besides. In many VB applications there are too
many "executive" decisions that it is impossible for any resizing control to
know of . . . unless the user tells it about them, and even then there will
be requirements that it won't actually be able to cope with. I know it will
cope in lots of circumstances, but there are lots of other circumstances in
which it won't. It's a personal decision of course, and if a particular
resizing control happens to suit your own needs then that's fine, but
personally I prefer to write my own resizing code.

Mike



 
 
Grand_Poobah





PostPosted: Sat Jun 30 22:59:17 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form That is absolutely true what you both say, but (there's always a but)
the target audience for my programs tends to be around my age (65) and
each and every one of them love my programs because if they expand it to
larger sizes, they get bigger fonts without screwing with the system
fonts. The buttons get bigger also which is a plus for them. I just
wish I could create bigger icons for the desktop.

6 years ago I wrote a nice banking program for a person with macular
degeneration and she uses it every day to do her banking online. For
every reason you state why you DON'T use a resizer, I am saying that's
the reason I DO!

Different strokes for different (age) folks <G>

--->
>


>>
>>> Mike:
>>> Have you looked at "ReSize OCX" by Larcome & Young?
>>
>> No. I would much sooner write my own resizing code. Besides, there is
>> no such thing as a resizing control that just works "as is" under all
>> conditions. It is not actually possible to write such a beast. Show me
>> a resizing Control that you just drop on a Form and forget it and I'll
>> show you a VB application on which it fails to work. The only resizing
>> control that would work for all VB applications is one that allows the
>> user (programmmer) to edit and modify its functions in lots of
>> different ways, and if you're going to edit and modify a resizing
>> control you might as well write it yourself in the first place ;-)
>>
>> Mike
>>
>>
>
> Too bad you're so hard set against this "drop in" control. That's all
> you do - drop it in and set two properties - Min Form Width and Min Form
> Height. That's it.
>
> I have been using it for almost 8 years now and have yet to find a
> control - VB provided or third-party that won't resize when you drag the
> borders. If you try to go too small it just refuses to move. Each and
> every control on it will resize to match -- fonts will adjust also.
>
> The OCX is provided on the left side of the IDE and all you have to do
> is compile your EXE. The VBP file will contain a reference to the OCX.
> The OCX will be delivered with your setup program as a run-time OCX
> (different from the developer OCX).
>
> Check it out a www.lyoung.com
>
> GP
 
 
Mike





PostPosted: Sun Jul 01 08:01:51 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form


> The buttons get bigger also which is a plus for them.
> I just wish I could create bigger icons for the desktop.

You can have your desktop icons almost any size you want, and you can change
the font size of the text underneath them, and you can alter their spacing
and all sorts of things. It is possible to alter the desktop in all sorts of
ways. It is of course up to the user to decide how they want their desktop
to look, but if the people you mention are having problems seeing things
they can set their display to 800 x 600 and alter their Windows dots per
inch setting, perhaps from 96 dpi to 120 dpi or whatever they are most
comfortable with, and it will alter the size of virtually everything,
including things which would not otherwise be altered by the various other
methods.

> . . . they love my programs because if they expand it
> to larger sizes, they get bigger fonts . . . The buttons
> get bigger also which is a plus for them.

But surely the reverse is also true. If they for some reason want to make
your own window smaller so that they can display something else on the
screen at the same time (which many people often want to do) then all your
text and your buttons will grow smaller ;-)

Mike



 
 
Grand_Poobah





PostPosted: Sun Jul 01 08:50:32 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form

>
>> The buttons get bigger also which is a plus for them.
>> I just wish I could create bigger icons for the desktop.
>
> You can have your desktop icons almost any size you want, and you can
> change the font size of the text underneath them, and you can alter
> their spacing and all sorts of things. It is possible to alter the
> desktop in all sorts of ways. It is of course up to the user to decide
> how they want their desktop to look, but if the people you mention are
> having problems seeing things they can set their display to 800 x 600
> and alter their Windows dots per inch setting, perhaps from 96 dpi to
> 120 dpi or whatever they are most comfortable with, and it will alter
> the size of virtually everything, including things which would not
> otherwise be altered by the various other methods.
>
>> . . . they love my programs because if they expand it
>> to larger sizes, they get bigger fonts . . . The buttons
>> get bigger also which is a plus for them.
>
> But surely the reverse is also true. If they for some reason want to
> make your own window smaller so that they can display something else on
> the screen at the same time (which many people often want to do) then
> all your
> text and your buttons will grow smaller ;-)
>
> Mike
>
>
>

I realize that about icons Mike, I have changed more than one desktop to
make everything larger, but what I meant was make just MY icon larger.

What we appear to be doing here is arguing about how many Angels can fit
on the head of a pin -- and we're using this thread to do it. <G>

GP
 
 
Steve





PostPosted: Sun Jul 01 12:59:18 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form



>
> What we appear to be doing here is arguing about how many Angels can fit on
> the head of a pin -- and we're using this thread to do it. <G>
>

I say 27 :)

The real underlying issue is that while Windows provides some ways to change the
size of text and buttons for all windows programs, not all windows programs
honor those settings consistently. Even MS programs will continue to put certain
elements in regular 8 pt type, when the system is set to use large fonts, or
what have you.

So then developers like Grand Poobah put code in their own programs to adjust
sizes, so that at least their program can be used by someone who needs larger
elements. And then we wind up with a hodge podge, where changing system settings
changes some things, and those conflict with programs that already provide their
own adjustments, and then there is no good solution left either way.

Ideally your macular degeneration customer would have been able to make a few
settings in Windows, and have all their programs resize appropriately, with big
buttons and big text. Alas, it is just not the case. I will continue to take my
eye drops, to reduce my intra-ocular pressure, and hopefully avoid ever needing
these kind of adjustments, since it is such a mish-mash these days.


 
 
Mike





PostPosted: Sun Jul 01 13:05:39 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form


> What we appear to be doing here is arguing about how
> many Angels can fit on the head of a pin -- and we're
> using this thread to do it. <G>

Well according to my Uncyclopedia the answer is 336.

http://uncyclopedia.org/wiki/Angels_on_the_head_of_a_pin

how many do you reckon it is? ;-)

Mike



 
 
Grand_Poobah





PostPosted: Sun Jul 01 14:11:33 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form

>
>> What we appear to be doing here is arguing about how
>> many Angels can fit on the head of a pin -- and we're
>> using this thread to do it. <G>
>
> Well according to my Uncyclopedia the answer is 336.
>
> http://uncyclopedia.org/wiki/Angels_on_the_head_of_a_pin
>
> how many do you reckon it is? ;-)
>
> Mike
>

Infinity - 1

GP

 
 
Jan





PostPosted: Mon Jul 02 03:48:47 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form
thoughts were released on Sat, 30 Jun 2007 20:20:51 -0400
bearing the following fruit:

>


>>
>>> Mike:
>>> Have you looked at "ReSize OCX" by Larcome & Young?
>>
>> No. I would much sooner write my own resizing code. Besides, there is no
>> such thing as a resizing control that just works "as is" under all
>> conditions. It is not actually possible to write such a beast. Show me a
>> resizing Control that you just drop on a Form and forget it and I'll
>> show you a VB application on which it fails to work. The only resizing
>> control that would work for all VB applications is one that allows the
>> user (programmmer) to edit and modify its functions in lots of different
>> ways, and if you're going to edit and modify a resizing control you
>> might as well write it yourself in the first place ;-)
>>
>> Mike
>>
>>
>
>Too bad you're so hard set against this "drop in" control. That's all
>you do - drop it in and set two properties - Min Form Width and Min Form
>Height. That's it.
>
>I have been using it for almost 8 years now and have yet to find a
>control - VB provided or third-party that won't resize when you drag the
>borders. If you try to go too small it just refuses to move. Each and
>every control on it will resize to match -- fonts will adjust also.
>
>The OCX is provided on the left side of the IDE and all you have to do
>is compile your EXE. The VBP file will contain a reference to the OCX.
>The OCX will be delivered with your setup program as a run-time OCX
>(different from the developer OCX).
>
>Check it out a www.lyoung.com
>

It's hard to tell from the website but it just makes
everything bigger or smaller yes?

This is no good. When I resise a form I want certain things
to grow, such as grids, pictures etc. But not buttons and
labels.

If they all grow then I gain nothing.



--
Jan Hyde

https://mvp.support.microsoft.com/profile/Jan.Hyde
 
 
Jan





PostPosted: Mon Jul 02 03:51:30 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form
released on Sat, 30 Jun 2007 06:25:53 -0700 bearing the
following fruit:



>> Hello,
>> User complains, that Vista cuts bottom of my app GUI and he cannot
>> accress controls placed in there.
>> In my Vista, only the edge is cut and I can access the controls at the
>> bottom.
>> What is the cause of that problem and how to redesign GUI ?
>
>If none of the other respones solves the problem then there is an issue in
>VB that can cause a strip of the form to not be displayed. I don't remember
>how to cause it but it has something to do with VB not allowing room for the
>menu bar so while the menu is shown OK at the top a strip at the bottom the
>same height as the menu is missing.

This only occurs in the IDE though, it should be fine on a
compiled version.

>The workaround is to open the code in the IDE, open the form in question so
>that you can see it and then compile. If you compile with the form designer
>window closed it can sometimes do it wrong.
>
>I've had this happen on at least Win2K and possibly Win9x systems although
>it's been a while since I last saw it

XP too although I've not noticed it since Vista.
--
Jan Hyde

https://mvp.support.microsoft.com/profile/Jan.Hyde
 
 
Grand_Poobah





PostPosted: Mon Jul 02 10:50:43 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form
> bearing the following:
>


>>>
>>>> Mike:
>>>> Have you looked at "ReSize OCX" by Larcome & Young?
>>> No. I would much sooner write my own resizing code. Besides, there is no
>>> such thing as a resizing control that just works "as is" under all
>>> conditions. It is not actually possible to write such a beast. Show me a
>>> resizing Control that you just drop on a Form and forget it and I'll
>>> show you a VB application on which it fails to work. The only resizing
>>> control that would work for all VB applications is one that allows the
>>> user (programmmer) to edit and modify its functions in lots of different
>>> ways, and if you're going to edit and modify a resizing control you
>>> might as well write it yourself in the first place ;-)
>>>
>>> Mike
>>>
>>>
>> Too bad you're so hard set against this "drop in" control. That's all
>> you do - drop it in and set two properties - Min Form Width and Min Form
>> Height. That's it.
>>
>> I have been using it for almost 8 years now and have yet to find a
>> control - VB provided or third-party that won't resize when you drag the
>> borders. If you try to go too small it just refuses to move. Each and
>> every control on it will resize to match -- fonts will adjust also.
>>
>> The OCX is provided on the left side of the IDE and all you have to do
>> is compile your EXE. The VBP file will contain a reference to the OCX.
>> The OCX will be delivered with your setup program as a run-time OCX
>> (different from the developer OCX).
>>
>> Check it out a www.lyoung.com
>>
>
> It's hard to tell from the website but it just makes
> everything bigger or smaller yes?
>
> This is no good. When I resise a form I want certain things
> to grow, such as grids, pictures etc. But not buttons and
> labels.
>
> If they all grow then I gain nothing.
>
>
>
> --
> Jan Hyde
>
> https://mvp.support.microsoft.com/profile/Jan.Hyde

Yes - they all grow. Application depends on your target user.

GP
 
 
Jack





PostPosted: Mon Jul 02 15:18:24 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form Thak you Rick.
Changing back to 96dpi has solved the problem but only partially.
User can now access controls located at the bottom of the form, but the form
still is cut at the bottom, apparently more then I can see that in my Vista.
Why is such difference?
Jack



>> User complains, that Vista cuts bottom of my app GUI and he cannot
>> accress controls placed in there.
>> In my Vista, only the edge is cut and I can access the controls at the
>> bottom.
>> What is the cause of that problem and how to redesign GUI ?
>
> I'd be willing to bet your user has his font settings at something other
> than the standard 96 dots per inch. You user can check by right-clicking
> on an empty spot on the Desktop and selecting Properties from the popup
> menu that appears. On the left side of the dialog box that comes up (under
> the panel with "Tasks" listed at the top) there is a hyperlink with the
> caption "Adjust font size (DPI)"... have the user click it and tell you
> what setting is shown.
>
> Rick


 
 
Jack





PostPosted: Mon Jul 02 15:39:26 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form Yes, I had that problem in IDE for years.
Interestingly, after changing many times computers and Windows, sometimes I
had that problem and sometimes not.
Run-time and compiled exe never show that problem.
I have never investigated the cause of that problem.
I am using vbasic5 SP3.
Jack





>> Hello,
>> User complains, that Vista cuts bottom of my app GUI and he cannot
>> accress controls placed in there.
>> In my Vista, only the edge is cut and I can access the controls at the
>> bottom.
>> What is the cause of that problem and how to redesign GUI ?
>
> If none of the other respones solves the problem then there is an issue in
> VB that can cause a strip of the form to not be displayed. I don't
> remember how to cause it but it has something to do with VB not allowing
> room for the menu bar so while the menu is shown OK at the top a strip at
> the bottom the same height as the menu is missing.
>
> The workaround is to open the code in the IDE, open the form in question
> so that you can see it and then compile. If you compile with the form
> designer window closed it can sometimes do it wrong.
>
> I've had this happen on at least Win2K and possibly Win9x systems although
> it's been a while since I last saw it
>


 
 
Mike





PostPosted: Tue Jul 03 03:04:44 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form


> Thak you Rick. Changing back to 96dpi has solved the
> problem but only partially. User can now access controls
> located at the bottom of the form, but the form still is cut
> at the bottom, apparently more then I can see that in my
> Vista. Why is such difference?

There are all sorts of possibilities. The dots per inch setting is just one
of them. Your own Vista may be running in standard mode while your user's
Vista might be running the Aero desktop, which will make all the caption
bars and stuff and the borders thicker, or you may have a thin taskbar and
your user might have a thicker one, or the taskbars may be in a different
position, I could go on for hours! If he is running Aero and you are not
then you could tell your user to run your own program in "non Aero" by right
clicking its shortcut and selecting Properties and placing a tick against
"disable desktop composition" under the Compatibility tab. But you really
should not be doing these things. Instead of forcing your user to change his
system to accommodate your program you should change your program to
accommodate your user! As I've already mentioned, your code needs to check
the available screen area *at run time*. If it is a fixed size Form and if
the desired Width or Height is greater than will fit onto the display you
need to reduce them accordingly. Your code then needs to examine the
resultant ScaleWidth and ScaleHeight properties of the Form and position all
Controls so that they fit within it. Similarly, if it is a maximized Form
then your code needs to examine the ScaleWidth and ScaleHeight *after* the
Form has loaded (and therefore after Windows has resized it) and reposition
all Controls so that they fit within it. In fact, to do it properly
everything on your Form should be positioned to your requirements at run
time, taking into account the available client area within your Form after
your Form has been resized to take account of the available desktop area. In
that way your code will still work fine on a machine that is set differently
to your own, and you would not have needed to tell your user to change his
dpi to 96 or to turn of Aero, which he might not actually be happy doing. In
fact if he has set his own system to 120 dpi then he will usually have a
very good reason of his own for having done so, and it is rude to tell him
to change it just to suit your own needs. This stuff is very easy to do.
There is really no excuse for failing to do it. Asking the user to make
changes to his system to accommodate your own failure to add such code
should not even be considered as an option. To start you off, here's an
example of how to get the available desktop area:

Option Explicit
Private Const SPI_GETWORKAREA = 48
Private Type RECT
Left As Long
Top As Long
Right As Long
Bottom As Long
End Type
Private Declare Function SystemParametersInfo Lib "user32" _
Alias "SystemParametersInfoA" (ByVal uAction As Long, _
ByVal uParam As Long, ByRef lpvParam As Any, _
ByVal fuWinIni As Long) As Long

Private Sub Command1_Click()
Dim myrect As RECT
Dim wide1 As Long, high1 As Long
Dim wide2 As Long, high2 As Long
Dim s1 As String
' get the total screen pixel area
wide1 = ScaleX(Screen.Width, vbTwips, vbPixels)
high1 = ScaleY(Screen.Height, vbTwips, vbPixels)
s1 = "Screen size is " & Format(wide1) & " x " _
& Format(high1) & " pixels." & vbCrLf
' get the "available" screen pixel area, not
' including taskbar and other similar bars
Call SystemParametersInfo(SPI_GETWORKAREA, 0&, myrect, 0&)
wide2 = myrect.Right - myrect.Left
high2 = myrect.Bottom - myrect.Top
s1 = s1 & "Available desktop area is " & Format(wide2) _
& " x " & Format(high2) & " pixels."
MsgBox s1
End Sub




 
 
Dave





PostPosted: Thu Jul 05 06:00:06 CDT 2007 Top

Visual Basic >> Vista cuts bottom of my form




>>
>>> What we appear to be doing here is arguing about how
>>> many Angels can fit on the head of a pin >
> Infinity - 1
>
> GP

I think you missed a couple, I make it infinity + 1,

Hmm, perhaps I've been lowering my intra-ocular pressure a bit too much
(An effective way to lower intra-ocular pressure, is to "ingest" ****
products)

Dave.