MSaccess RELATIONSHIP view of an mdb created by vc++

Hello,

I have a VC++ program to create (from scratch !) a MDB with several tables as well as some 1:n relations between them. It works fine.
When I close the vc++ program and look at the mdb file (by opening MS Access, then click on RELATIONSHIP icon), then I get a graphical overview of the database. The bug is: some tables are displayed, others are NOT displayed. I want full control of which table to display and which not. Now it seems random. So :
1.) what is the command to tell to dao: "display table XY on pressing <Relationship> in MS Access" ?
2.) Can I also control the layout of the different tables (where are they positioned inside the relationship display) ?

I am NOT interested in any solutions inside  MS Access, I want the problem to be solved in my vc++ program, at the moment of the creation of the MDB.

Sonja

Sonja_MAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

DatabaseMX (Joe Anderson - Microsoft Access MVP)Database Architect / Systems AnalystCommented:
You have basically posted the same question again.  Please delete one or the other.

mx
0
Sonja_MAuthor Commented:
theother is deleted.
0
Scott McDaniel (Microsoft Access MVP - EE MVE )Infotrakker SoftwareCommented:
No, you cannot manipulate the relationships window, and it's somewhat buggy at best. Tables sometimes display and other times do not.

The diagram is simply a graphical representation of the relationships, but it has nothing to do with the actual relationships.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
The Ultimate Tool Kit for Technolgy Solution Provi

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy for valuable how-to assets including sample agreements, checklists, flowcharts, and more!

DatabaseMX (Joe Anderson - Microsoft Access MVP)Database Architect / Systems AnalystCommented:
0
Sonja_MAuthor Commented:
Hello LSMConsulting,

thanks a lot for your answer !
> Tables sometimes display and other times do not.
my impression is different: I have 32 tables, and my impression is: always the SAME 15 tables get displayed, after closing my vc++ program and opening ms access. It seems to not depend on whether I create the MDB from scratch or whether I change some records in the mdb, using my vc++ program.

> The diagram is simply a graphical representation of the relationships,
I understand, and this is perfect.

> but it has nothing to do with the actual relationships.
this I do not understand. Can you explain in other words ?

best regards, Sonja

0
TextReportCommented:
The Relationship window is a graphical representation held for each ACCESS user, the default user being admin. This could be the reason you beleive that the views are random, you could be looking at it from different users.

There is NO automation of the graphical representation, however, you can program the relationships themselves. Try adding All Tables and save. When you close the Relationship window you should get an option to save it.

Cheers, Andrew
0
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database Architect / Systems AnalystCommented:
"Try adding All Tables and save. When you close the Relationship window you should get an option to save it."

TR ... see this same Q link http://www.experts-exchange.com/Programming/Languages/CPP/Q_23115129.html

I already mentioned that ...and she "is not interested in that solution"

mx
0
Sonja_MAuthor Commented:
Hello Andrew,


> The Relationship window is a graphical representation held for each ACCESS user, the default user being admin.
interesting ! In my case, however, the PC is not in a network, and I am logged in as admin.

> This could be the reason you beleive that the views are random, you could be looking at it from different users.
it is random in the sense of: I do not see the logic behind how tables are selected to be shown. But it is constant / predictable in the sense of: there are always the same tables missing & the same tables displayed.

> There is NO automation of the graphical representation, however, you can program the relationships themselves.
yes, I have already done this, in vc++.

> Try adding All Tables and save. When you close the Relationship window you should get an option to save it.
this is a solution inside MS Access :-(


Thanks for your interesting thoughts. Sonja
0
TextReportCommented:
MX this is http://www.experts-exchange.com/Programming/Languages/CPP/Q_23115129.html
perhaps you mean "VC++/DAO creates MDB, but MSAccess does not show all tables." http://www.experts-exchange.com/Microsoft/Development/.NET/Visual_CPP/Q_23114990.html.

Either way it is not possible to code and atleast a consistant message is being presented.

Cheers and best wishes, Andrew
0
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database Architect / Systems AnalystCommented:
"But it is constant / predictable in the sense of: there are always the same tables missing & the same tables displayed."

Note that *only* tables that have relationships established between them are going to show in the Relationship window.  I asked this question before:  Do you have relationships defined between ALL of the tables?  Or just between the 15 that are showing ?  Of course, form within Access, you and drag on or add a table to the diagram, whether or not it's in a relationship. But opening the window from VC++ (or doing the Show All from Access) is only going to show tables in a relationship.

mx
0
TextReportCommented:
Hi sonja

"there are always the same tables missing & the same tables displayed." means that is was saved with these tables against your admin user in the MDB.

When you are creating the MDB from scratch is it a CreateDatabase command that you are executing or could it be copying an MDB as a template?

Cheers, Andrew
0
Sonja_MAuthor Commented:
actually, mx has found the solution, but only thanks to the good answers of all other experts. My warmest thanks and best wishes go to  Andrew, TextReport and LSMConsulting. - Sonja
0
DatabaseMX (Joe Anderson - Microsoft Access MVP)Database Architect / Systems AnalystCommented:
So, what was ... the solution ??  What did I find ?

mx
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Development

From novice to tech pro — start learning today.