Dynamic Control Creation - Expand Form? 
Author Message
 Dynamic Control Creation - Expand Form?

 When you dynamically create controls (e.g. a series of text boxes) on
a form, is there a way to make the form expand to contain all of the
controls? Or will the form automatically put vertical/horizontal scroll
bars in place to view the controls off the page? I am just beginning a
project which requires dynamic generation, and want to do it right the
first time. I am using VB5.0 with Window98and Access97.

Thanks in advance..........

--
Tim Pascoe
GIS and Environmental Applications Specialist
National Water Research Institute
Canada Center for Inland Waters

Sent via Deja.com http://www.*-*-*.com/
Share what you know. Learn what you don't.



Sat, 02 Feb 2002 03:00:00 GMT  
 Dynamic Control Creation - Expand Form?

Quote:

>  When you dynamically create controls (e.g. a series of text boxes) on
> a form, is there a way to make the form expand to contain all of the
> controls? Or will the form automatically put vertical/horizontal
> scroll bars in place to view the controls off the page?

No.

The way I ususally do is, instead of putting them directly on a form,
put all the controls inside a panel(InsidePanel) inside another panel
(OuterPanel). Adjust the InsidePanel.width and InsidePanel.length to
accomodate all the controls whenever you add a new control. The
OuterPanel should fit the length and width of the form (so customize
OuterPanel.Width and OuterPanel.Length in the form_resize event). Put a
scroll bar (or two) on the form. Use the value of the scroll bars to
control the top and left position of the InsidePanel, essentially
moving it inside the OuterPanel.

Quote:
>I am just beginning a
> project which requires dynamic generation, and want to do it right the
> first time.

Thats not good for job security.

Quote:
>I am using VB5.0 with Window98and Access97.

> Thanks in advance..........

> --
> Tim Pascoe
> GIS and Environmental Applications Specialist
> National Water Research Institute
> Canada Center for Inland Waters

> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.

-Amos Yung

Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.



Sat, 02 Feb 2002 03:00:00 GMT  
 Dynamic Control Creation - Expand Form?
You might want to take a look at some Pager type controls.
Quote:

> When you dynamically create controls (e.g. a series of text boxes) on
> a form, is there a way to make the form expand to contain all of the
> controls? Or will the form automatically put vertical/horizontal scroll
> bars in place to view the controls off the page? I am just beginning a
> project which requires dynamic generation, and want to do it right the
> first time. I am using VB5.0 with Window98and Access97.

> Thanks in advance..........

> --
> Tim Pascoe
> GIS and Environmental Applications Specialist
> National Water Research Institute
> Canada Center for Inland Waters

> Sent via Deja.com http://www.deja.com/
> Share what you know. Learn what you don't.



Sun, 03 Feb 2002 03:00:00 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Dynamic Controls Creation and Referencing the new Control.

2. Dynamic Control Creation, Controls object has no .Add ???

3. Runtime Creation of Dynamic Forms

4. Dynamic Creation of Object Names - Forms

5. Dynamic Form Creation

6. Form dynamic creation

7. Dynamic form creation

8. Grabbing stuff from form / dynamic variable creation (?)

9. Dynamic Forms Creation on the Fly

10. Dynamic Form Creation

11. dynamic form name creation

12. Dynamic Form creation?

 

 
Powered by phpBB® Forum Software