Steve I had a couple of hours to kill tonight so I put together a sample
MDB to Save or Restore the current layout fo the Relationship View
window. It requires a more functional GUI and better DAO interface and
error handling but it does work.
NEW - Jan 21/2004 A2KSave-RestoreRelationshipWindow.zip is an MDB
containing functions to Save and Restore the Relationships View Window.
Allows an unlimited number of different Relationship Window Views to be
saved.
http://www.lebans.com/saverelationshipview.htm
Here is the Access97 version:A97Save-RestoreRelationshipWindow.zip
--
HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.
"Steve Jorgensen" <nospam@nospam.nospam> wrote in message
news:0mne00ds5uc0goobdmt00e739mrvlf6335@4ax.com...[color=blue]
> On Fri, 16 Jan 2004 03:25:34 GMT, "Stephen Lebans"
> <ForEmailGotoMy.WebSite.-WWWdotlebansdotcom@linvalid.com> wrote:
>[color=green]
> >I know decoding the BLOB is the proper way to accomplish what you[/color][/color]
want[color=blue][color=green]
> >to do but I can suggest an alternative method.
> >Each of the Table objects in the Relationship window is comprised of[/color][/color]
two[color=blue][color=green]
> >windows. THe parent window is of the class OEcl and it contains a[/color][/color]
child[color=blue][color=green]
> >ListBox control window.
> >I just tried and you can use GetWIndowText to retrieve the Caption of
> >each of the table object windows which corresponds to the table's[/color][/color]
name.[color=blue][color=green]
> >You can also get at each of the Fields/Expressions contained in the
> >child ListBox control. I have previously coded a solution to loop
> >through all of the windows in the Relationship WIndow in order to[/color][/color]
find[color=blue][color=green]
> >and repair any windows that have dropped off of the main[/color][/color]
window(happens[color=blue][color=green]
> >when you switch video card resolutions).
> >So you could easily save off the current dimesions and location of[/color][/color]
each[color=blue][color=green]
> >window to a file in order to restore the Relationship view at a later
> >time.
> >The code to play around with is in the Utilities MDB on my site in[/color][/color]
the[color=blue][color=green]
> >MISC section. THe code is minimal and was written for a NG poster[/color][/color]
whom[color=blue][color=green]
> >had lost a few windows off of the left edge of the Relationship[/color][/color]
window.[color=blue][color=green]
> >
> >I'm not sure if this solves your issue or not Steve. I'd be glad to[/color][/color]
help[color=blue][color=green]
> >you put together a finished solution if you want.[/color]
>
> Actually, that sounds like it probably will handle my situation. If I[/color]
know[color=blue]
> what windows are there, and what their positions and sizes are, and if[/color]
I have[color=blue]
> a way to move/size the windows again later, then I just need to see if[/color]
there's[color=blue]
> something under DoCmd. to show and hide tables. If this works, I[/color]
actually[color=blue]
> think it would be more "proper" than decoding the blob.
>
> I'll try it out, and see how far I get.[/color]