Solved

How to create parent to child tabbed windows

Posted on 2001-06-23
9
220 Views
Last Modified: 2010-05-02
i need to create a vb program that shows address book entries in the main view (window A). i need two more windows one for documents (window b)related to the address book entry that is selected and one for notes (window c)related to the address book entry that is selected as the user selects a new address book entry i  want the data in the documents and notes to change match. I need each window to be linked to a corrosponding table using ADO.

I have not started this and would appreciate code examples links and helpfull tips, i have more points if needed.

layout

--------------------------
|                         |
|  window a               |
|                         |
--------------------------
|          |              |
| window b | window c     |
--------------------------


Thanks in Advance

0
Comment
Question by:krisjob
  • 4
  • 2
  • 2
  • +1
9 Comments
 
LVL 4

Expert Comment

by:wileecoy
ID: 6221798
Question:

Are all of these windows on one form? or are they different forms?

Also - is this a single document interface, or multiple document interface?

Do you have the databases set-up?
0
 
LVL 1

Expert Comment

by:khampton
ID: 6222405
The link you refer to can be acheived in several ways.  I prefer to use events and code.

If an item is selected in view A, you will know because an event will be triggered (MouseUp for instance).

In this event, add the code to call a routine that will populate a recordset via a "Select * from MyTable Where ForeignKey = SelectedKey" (SelectedKey is the value of the item selected in view A and ForeignKey is the "linking or relational field(s)" for the data to displayed on the views).

Then put the fields into labels or textboxes residing on the view b and view c as desired.

0
 

Author Comment

by:krisjob
ID: 6222483
I have not got a database set up yet and would use a MDI interface.
0
 
LVL 4

Expert Comment

by:wileecoy
ID: 6222760
So your WindowA, WindowB, WindowC are all seperate forms within the same MDI application?  Yes?

I would agree with khampton in terms of using the events to trigger code that will update the data in the other two forms.

I can give you an example if this is what you are looking for, but it would require a lot of assumptions on my part.
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 

Author Comment

by:krisjob
ID: 6222920
code would be nice, as i say i need an example. from this example i could laern how it works.

thanks

0
 
LVL 8

Expert Comment

by:glass_cookie
ID: 6223581
Hi!

Here's a link for you:

Download...
http://www.vb-helper.com/Howto/mdichild.zip
Description: Arrange MDI child forms (3K)


Download..
http://www.vb-helper.com/Howto/ado6.zip
Description: Use GetRows to load data from an ADO Recordset into an array (7K)

Download...
http://www.vb-helper.com/Howto/ado6.zip
Description: Display selected fields from a database using ADO and a grid (8K)

This may be applicable (just in case)

Download...
http://www.vb-helper.com/Howto/dbtocbo.zip
Description: Load a ComboBox and ListBox from a database (8K)


That's it!

glass cookie : )
0
 
LVL 8

Accepted Solution

by:
glass_cookie earned 300 total points
ID: 6223591
One more : )

Download...
http://www.planetsourcecode.com/upload/ftp/CODE_UPLOAD1811.zip

Description: This is an example of a DAO DATABASE CONNECTION PROGRAM Este es un ejemplo de un PROGRAMA DE CONECTIVIDAD A UN BASE DE DATOS POR DAO. This program contains an english part, for those that speak english. Este programa contiene un parte en espa?ol, para aquellos que hablan espa?ol.

That's it!

glass cookie : )
0
 
LVL 8

Expert Comment

by:glass_cookie
ID: 6223593
The above title: Address Book - Directorio Telefonico
0
 
LVL 8

Expert Comment

by:glass_cookie
ID: 6223601
Download...
http://www.planetsourcecode.com/upload/ftp/CODE_UPLOAD5594582000.zip

Description: TOTAL DATABASE APP. add/delete/update/edit/SEARCH everything you expect from a good database address book/donation records/ and REPORT of donation a user has made over a certain time

Download...
http://www.planetsourcecode.com/upload/ftp/CODE_UPLOAD228612141999.zip

Description: Heres the update to my Address Book Example that pulls it information from an Access Database. I finally added the search and delete functions because I got tired of getting email from people asking me to write the update. :) Sorry it took so long but I've been busy opening up my office... Email any questions you have or comments to plexxonic@softhome.net

That's it!

glass cookie : )
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now