Connecting Tech Pros Worldwide Help | Site Map

Unhide Database Window

caimito
Guest
 
Posts: n/a
#1: Nov 13 '05
Hello to the group. I have been unsuccessful at unhiding the database
window via code. The most I have gotten is to open the unhide dialogue from
a command button on a form, but then I still have to select the datbase from
the dialogue box and click unhide. Is there a more direct method via code?
I use access 2000 but am transitioning to access 2003.


dixie
Guest
 
Posts: n/a
#2: Nov 13 '05

re: Unhide Database Window


Caimito, try this code to unhide
DoCmd.SelectObject acTable, , True
DoCmd.RunCommand acCmdWindowHide
DoCmd.ShowToolbar "Container", acToolbarNo

Then to rehide
DoCmd.SelectObject acTable, , True
DoCmd.ShowToolbar "Container", acToolbarYes

I have the code in a module and I access it via an autokeys macro, which
means that when I hit the right combination of keys, it unhides it, then by
hitting another combination, I can hide it.

dixie

"caimito" <caimito@optonline.net> wrote in message
news:4lUkd.66590$fF6.30468561@news4.srv.hcvlny.cv. net...[color=blue]
> Hello to the group. I have been unsuccessful at unhiding the database
> window via code. The most I have gotten is to open the unhide dialogue
> from a command button on a form, but then I still have to select the
> datbase from the dialogue box and click unhide. Is there a more direct
> method via code? I use access 2000 but am transitioning to access 2003.
>[/color]


Allen Browne
Guest
 
Posts: n/a
#3: Nov 13 '05

re: Unhide Database Window


Use SelectObject, with True for the InDatabaseWundow argument, e.g.:

DoCmd.SelectObject acTable,,True

--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"caimito" <caimito@optonline.net> wrote in message
news:4lUkd.66590$fF6.30468561@news4.srv.hcvlny.cv. net...[color=blue]
> Hello to the group. I have been unsuccessful at unhiding the database
> window via code. The most I have gotten is to open the unhide dialogue
> from a command button on a form, but then I still have to select the
> datbase from the dialogue box and click unhide. Is there a more direct
> method via code? I use access 2000 but am transitioning to access 2003.[/color]


Imageek2
Guest
 
Posts: n/a
#4: Nov 13 '05

re: Unhide Database Window


I received two responses and they both were helpful. The selectobject
method single line suggestion was the simplest. Although I tried to use
the longer response I did not find the toolbar "container". To hide the
database window again I simply used the selectobject and used the hide
method. Why didn't MS just include the unhide method as well? Anyway
thanks much for both responses.



*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
dixie
Guest
 
Posts: n/a
#5: Nov 13 '05

re: Unhide Database Window


Sorry, imagegeek2, the DoCmd.ShowToolbar "Container", acToolbarNo and its
Yes version referred to a specific toolbar on my system. Didn't mean to
confuse you, just didn't think. Brain in neutral lately :-)

dixie

"Imageek2" <nospam@devdex.com> wrote in message
news:41975f3f$0$14480$c397aba@news.newsgroups.ws.. .[color=blue]
>I received two responses and they both were helpful. The selectobject
> method single line suggestion was the simplest. Although I tried to use
> the longer response I did not find the toolbar "container". To hide the
> database window again I simply used the selectobject and used the hide
> method. Why didn't MS just include the unhide method as well? Anyway
> thanks much for both responses.
>
>
>
> *** Sent via Developersdex http://www.developersdex.com ***
> Don't just participate in USENET...get rewarded for it![/color]


Closed Thread