
borderless form automatically resizes?
Another approach would be to specify the form size in the Form_Load
sub...that way you could force the size and location of the window.
I also found that sizing and moving a window with .Visible=False is
problematic. The workaround I use is to start with the form not visible,
then do a SuspendLayout, make the form visible, relocate/resize it and then
ResumeLayout. While it seems like hoops to jump through, I'll do it until
it's fixed (whenever that is)...
--- Jim ---
Quote:
> hi bob,
> i managed to get it to do what i want - basically if i want the form size
to
> be 100x100 (say) at runtime then at designtime i make it slightly smaller
> than that 96x96 (say). so at runtime when the form resizes it resizes to
> the size i want!
> takes a little bit of experimentation but i got there in the end.
> t.
> > You think that's fun, wait until you notice that the form is also
> > automatically moved for you, too, whenever it is made visible. Last time
I
> > inquired about this an [MS] guy said he would inquire as to whether this
> was
> > a bug or by design. He never got back to me. IMHO it's design flaw (even
> if
> > they say it's a 'feature') which probably won't be corrected any time
> soon.
> > Bob
> > > hi,
> > > i have a borderless (FormBorderStyle = None) form.
> > > on this form i have placed a datepicker control. i resized
> > > the form so that the datepicker fits nicely inside with a very small
> > > margin around the edge.
> > > when i run and display this form i notice that it has "automatically"
> > > resized itself and is now bigger than what it appears to be in the
> > > design view.
> > > any ideas please?
> > > thnx.
> > > t.