Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

multiple frames during runtime

Status
Not open for further replies.

kartheterrible

Programmer
Mar 6, 2007
2
0
0
US
I have an applcation using frames. I'd like to be able to add multiple instances of the same frame during runtime. I do not know how many frames I will need in advance, as that number is computed during runtime.

If I try to use the "new" operator and add more than one instance of a frame (say TFrame1), my app throws an exception. So how do I get around thsi problem?

One hack is to overestimate the number of frames at design time and hide the extra ones. Of course this is isnt my preferred design as its bound to break at some point.

Any ideas? Thanks a lot

K
 
Can you show us the code you are using with new?


James P. Cottingham
-----------------------------------------
[sup]I'm number 1,229!
I'm number 1,229![/sup]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top