|
-
Mar 4th, 2003, 02:03 PM
#1
Thread Starter
Banned
tabs
i want to be able to create an application in vb with a split tabbed pane. But the problem is each tab has to have a sub form. Will this be possible. Meaning this is a db app...the main form frmMain pertains to a proposal. Then I have a tab transports that has to have its own form called transports...BUT even on this form transports I need another subform for transport components.
Is this possible?
JJon
-
Mar 4th, 2003, 02:19 PM
#2
Fanatic Member
if i understand correctly, you want to have all the tabs' controls on a single form? would using frame controls to group your tab views, instead of forms, help in any way?
-
Mar 4th, 2003, 02:21 PM
#3
Thread Starter
Banned
No id like one form the main form to be a tabbed form...but inside each of the tabs have a sub form placed in them. Also inside one of the subforms I need another subform...
Jon
-
Mar 4th, 2003, 02:33 PM
#4
Fanatic Member
you cant make a tabbed dialog control span multiple forms, that's for sure. so you have to somehow 'simulate' the whole thing, by setting the position of your forms and displaying them on and off. there's a way to get rid of the top blue part of the form, but i cant remember it right now - im sure you can get some help about this from the folks. as long as you leave the user the possibility to resize or move your forms, they can easily mess up all your GUI
-
Mar 4th, 2003, 02:35 PM
#5
Thread Starter
Banned
hmm access supports subforms on top of tabbed panes...
im very surprised vb doesnt???
How does a developer establish a one to many relationship in his / her app....several times.
Meaning I know one can come up with a customer to order relationship via an MDI form. But what if you spanned across a few tabs and wanted sub forms within each tab...
Jon
-
Mar 4th, 2003, 02:42 PM
#6
Fanatic Member
yeah, theres no such thing as 'subform' in vb.
the easy way to have multiple instances of a form generated from the same template is to use something like
VB Code:
Dim iForm As New kindofMyForm
iForm.Show
provided you already have designed a form with the name kindofMyForm. i hope this answers your 2nd part of the question.
-
Mar 4th, 2003, 02:43 PM
#7
Thread Starter
Banned
I need to look at this in a relational fashion and not gui before i establish anything. Will my second form know about my first form...primary key to foreign key we are talking here.
Wheres the db gurus?
Jon
-
Mar 4th, 2003, 02:53 PM
#8
Fanatic Member
sure you can do that. you can declare a public variable in the child form that would store a reference to the parent form. you can either have this variable of Integer type or something, relating to a 'tag' in the parent form, but the easiest way is to have the variable declared as Form, or even as the specific type of form the parent is. in other words, if the parent form's name is daddyForm, you can declare the relationship in the child form with
and then access the controls and methods on the daddyForm like
VB Code:
someText = parent.Text1.Text
this is even cooler than a foreign key relationship, because you dont have to iterate thru all your possible daddy and children forms to find the one you need - you have the reference to it right upfront. i would suggest to use intensively the underestimated 'Tag' property of the forms, which works pretty good as a hidden way of labeling them.
-
Mar 4th, 2003, 02:55 PM
#9
Thread Starter
Banned
im not worried about accessing fields from the daddy..im worried about relational structure...i need to maintain referential integrity between a parent / child relationship and find it rather stupid that what im trying to do is not possible...if i knew that i would have stuck to an access front end.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|