I'm terrible with VBA so this might be something really simple. In
Access 2007, I have a startup form with this event on load:
Private Sub Form_Load()
DoCmd.SelectObject acTable, , True
DoCmd.RunCommand acCmdWindowHide
DoCmd.ShowToolbar "Ribbon", acToolbarNo
End Sub
and this on close:
Private Sub Form_Close()
DoCmd.SelectObject acTable, , True
DoCmd.ShowToolbar "Ribbon", acToolbarYes
End Sub
I've also tried the first event as on open and there is no apparent
difference in functionality. I got the code from searching for ways
to hide the ribbon and navigation pane. These codes work perfectly
for the navigation pane but don't seem to affect the ribbon at all.
I've also tried splitting the first event up between on open and on
load (hiding the nav pane on open and the ribbon on load) but that
didn't work either. Any ideas on why hiding the ribbon isn't
working? I swear I've gotten this to work before, without having to
create a custom ribbon or anything, I just can't remember how.
|
|
0
|
|
|
|
Reply
|
esn
|
6/4/2010 4:46:54 PM |
|
Hi,
Hide Ribbon and menus:
DoCmd.ShowToolbar "Ribbon", acToolbarNo
Show Ribbon and menus:
DoCmd.ShowToolbar "Ribbon", acToolbarYes
Hide navigaionpanel:
DoCmd.SelectObject acTable, , True
RunCommand acCmdWindowHide
Show navigationpanel:
DoCmd.SelectObject acTable, , True
Regards
J�rn Bosse
Am 04.06.2010 18:46, schrieb esn:
> I'm terrible with VBA so this might be something really simple. In
> Access 2007, I have a startup form with this event on load:
>
> Private Sub Form_Load()
> DoCmd.SelectObject acTable, , True
> DoCmd.RunCommand acCmdWindowHide
> DoCmd.ShowToolbar "Ribbon", acToolbarNo
> End Sub
>
> and this on close:
>
> Private Sub Form_Close()
> DoCmd.SelectObject acTable, , True
> DoCmd.ShowToolbar "Ribbon", acToolbarYes
> End Sub
>
> I've also tried the first event as on open and there is no apparent
> difference in functionality. I got the code from searching for ways
> to hide the ribbon and navigation pane. These codes work perfectly
> for the navigation pane but don't seem to affect the ribbon at all.
> I've also tried splitting the first event up between on open and on
> load (hiding the nav pane on open and the ribbon on load) but that
> didn't work either. Any ideas on why hiding the ribbon isn't
> working? I swear I've gotten this to work before, without having to
> create a custom ribbon or anything, I just can't remember how.
|
|
0
|
|
|
|
Reply
|
ISO
|
6/4/2010 8:52:05 PM
|
|
> Hide Ribbon and menus:
> DoCmd.ShowToolbar "Ribbon", acToolbarNo
>
> Show Ribbon and menus:
> DoCmd.ShowToolbar "Ribbon", acToolbarYes
>
> Hide navigaionpanel:
> DoCmd.SelectObject acTable, , True
> =A0 =A0 =A0RunCommand acCmdWindowHide
>
> Show navigationpanel:
> DoCmd.SelectObject acTable, , True
Yeah so why isn't it working?
|
|
0
|
|
|
|
Reply
|
esn
|
6/4/2010 9:15:52 PM
|
|
Am 04.06.2010 23:15, schrieb esn:
>> Hide Ribbon and menus:
>> DoCmd.ShowToolbar "Ribbon", acToolbarNo
>>
>> Show Ribbon and menus:
>> DoCmd.ShowToolbar "Ribbon", acToolbarYes
>>
>> Hide navigaionpanel:
>> DoCmd.SelectObject acTable, , True
>> RunCommand acCmdWindowHide
>>
>> Show navigationpanel:
>> DoCmd.SelectObject acTable, , True
>
> Yeah so why isn't it working?
Did you create a secure folder in the security center? Or do you always
have to choose "Allow Macros" or something like this, when your db starts?
|
|
0
|
|
|
|
Reply
|
ISO
|
6/4/2010 9:35:45 PM
|
|
Thanks for checking in again,
> Did you create a secure folder in the security center? Or do you always
> =A0 have to choose "Allow Macros" or something like this, when your db st=
arts?
The db is in a "trusted location," so events/macros aren't blocked,
plus I have my default setting at "allow all macros" because the only
db files I open are ones I built myself. Anything else it could be?
|
|
0
|
|
|
|
Reply
|
esn
|
6/4/2010 9:46:10 PM
|
|
Well,
try to create a button which executes the code. I just checked ist and
it works fine. If that doesn�t hel, you may create a module with a
public function. Create a macro called autoexec which executes this
function.
You could show up a messagbox when loading your startform to check if
code is about to be executed on startup.
J�rn
Am 04.06.2010 23:46, schrieb esn:
> Thanks for checking in again,
>
>> Did you create a secure folder in the security center? Or do you always
>> have to choose "Allow Macros" or something like this, when your db starts?
>
> The db is in a "trusted location," so events/macros aren't blocked,
> plus I have my default setting at "allow all macros" because the only
> db files I open are ones I built myself. Anything else it could be?
|
|
0
|
|
|
|
Reply
|
ISO
|
6/4/2010 10:04:25 PM
|
|
On Jun 4, 3:04=A0pm, J=F6rn Bosse <joernbo...@gmx.de> wrote:
> Well,
>
> try to create a button which executes the code. I just checked ist and
> it works fine. If that doesn=B4t hel, you may create a module with a
> public function. Create a macro called autoexec which executes this
> function.
> You could show up a messagbox when loading your startform to check if
> code is about to be executed on startup.
>
> J=F6rn
>
> Am 04.06.2010 23:46, schrieb esn:
>
> > Thanks for checking in again,
>
> >> Did you create a secure folder in the security center? Or do you alway=
s
> >> =A0 =A0have to choose "Allow Macros" or something like this, when your=
db starts?
>
> > The db is in a "trusted location," so events/macros aren't blocked,
> > plus I have my default setting at "allow all macros" because the only
> > db files I open are ones I built myself. =A0Anything else it could be?
I know the code is loading on startup because it hides the navigation
pane like it should. I tried putting the code in the on click event
of a button and it still doesn't do anything. I've pored over the
options and can't find anything that would be blocking this particular
line of code. Is there any chance I accidentally renamed the ribbon
or something like that?
|
|
0
|
|
|
|
Reply
|
esn
|
6/5/2010 6:15:31 PM
|
|
On Jun 5, 11:15=A0am, esn <ericnewk...@gmail.com> wrote:
> On Jun 4, 3:04=A0pm, J=F6rn Bosse <joernbo...@gmx.de> wrote:
>
>
>
> > Well,
>
> > try to create a button which executes the code. I just checked ist and
> > it works fine. If that doesn=B4t hel, you may create a module with a
> > public function. Create a macro called autoexec which executes this
> > function.
> > You could show up a messagbox when loading your startform to check if
> > code is about to be executed on startup.
>
> > J=F6rn
>
> > Am 04.06.2010 23:46, schrieb esn:
>
> > > Thanks for checking in again,
>
> > >> Did you create a secure folder in the security center? Or do you alw=
ays
> > >> =A0 =A0have to choose "Allow Macros" or something like this, when yo=
ur db starts?
>
> > > The db is in a "trusted location," so events/macros aren't blocked,
> > > plus I have my default setting at "allow all macros" because the only
> > > db files I open are ones I built myself. =A0Anything else it could be=
?
>
> I know the code is loading on startup because it hides the navigation
> pane like it should. =A0I tried putting the code in the on click event
> of a button and it still doesn't do anything. =A0I've pored over the
> options and can't find anything that would be blocking this particular
> line of code. =A0Is there any chance I accidentally renamed the ribbon
> or something like that?
Update - I tried putting it on a form in a completely empty blank
database and it does the trick. So why is the database I'm working on
not reading that particular line of code? I took a look at some of
the system tables to see if anything jumped out but that's all way
over my head.
|
|
0
|
|
|
|
Reply
|
esn
|
6/5/2010 6:22:37 PM
|
|
I just remembered having a problem with the VBA references of a
previous database file. I had to go into the tools menu and de-select
a few references, close, reopen, and re-select the referenced
libraries. Any chance this is something similar - some sort of broken
object reference or something? I tried running through this process,
but Access wouldn't let me remove the first two references in the
list, since there are objects that depend on them. Could the problem
be in one of those? If so, what do I do to fix it?
|
|
0
|
|
|
|
Reply
|
esn
|
6/5/2010 6:51:57 PM
|
|
If you didn�t disabled the VBA Project ref everything should work with
that code. You cant change the name of the Ribbon toolbar at all. Would
you please try that code in an other db?
If you want to, you can send me that db, via email but please with no
data inside. Then i can figure out whats wrong and not only suggesting
what it could be. This would be a lot faster.
Regards
J�rn
Am 05.06.2010 20:51, schrieb esn:
> I just remembered having a problem with the VBA references of a
> previous database file. I had to go into the tools menu and de-select
> a few references, close, reopen, and re-select the referenced
> libraries. Any chance this is something similar - some sort of broken
> object reference or something? I tried running through this process,
> but Access wouldn't let me remove the first two references in the
> list, since there are objects that depend on them. Could the problem
> be in one of those? If so, what do I do to fix it?
|
|
0
|
|
|
|
Reply
|
ISO
|
6/6/2010 12:54:39 AM
|
|
Thanks for the offer, but I think it's hopeless. I've tried
everything I can think of and the only viable solution seems to be
copying all the objects into a new file. I have already tried the
code in another database and it works perfectly. I also tried making
a custom ribbon and that works when viewing reports, but it doesn't
work when viewing forms. Something has gone wrong with this file
somewhere, but it's easier to construct a new one than to try to track
it down. I've also tried saving a different copy of the same file,
running the code in an older version, etc. Nothing seems to solve the
issue.
|
|
0
|
|
|
|
Reply
|
esn
|
6/7/2010 2:16:09 PM
|
|
Hi there,
thats what i actually would have done, too ;)
I think that�s the best solution...
Well but sometimes i had some luck with decompiling, but you should only
do this with a copy of your database.
regards
J�rn
Am 07.06.2010 16:16, schrieb esn:
> Thanks for the offer, but I think it's hopeless. I've tried
> everything I can think of and the only viable solution seems to be
> copying all the objects into a new file. I have already tried the
> code in another database and it works perfectly. I also tried making
> a custom ribbon and that works when viewing reports, but it doesn't
> work when viewing forms. Something has gone wrong with this file
> somewhere, but it's easier to construct a new one than to try to track
> it down. I've also tried saving a different copy of the same file,
> running the code in an older version, etc. Nothing seems to solve the
> issue.
|
|
0
|
|
|
|
Reply
|
ISO
|
6/7/2010 3:31:40 PM
|
|
|
11 Replies
2379 Views
(page loaded in 1.229 seconds)
Similiar Articles: Hide ribbon event not working - microsoft.public.access.forms ...I'm terrible with VBA so this might be something really simple. In Access 2007, I have a startup form with this event on load: Private Sub Form_L... Hide Tab in Ribbon - microsoft.public.access.modulesdaovba ...Hide or Display Ribbon Tab/Group/Control with getVisible MyTag = "show" in the Workbook_Open event in the ... Because getVisible is not working for Built-in Tabs ... in ... Load event not working - microsoft.public.accessHide ribbon event not working - microsoft.public.access.forms ... I'm terrible with VBA so this might be something really simple. In Access 2007, I have a startup form ... How can I switch off auto-hide ribbon (Quick Access Toolbar ...Hide ribbon event not working - microsoft.public.access.forms ... Display custom Ribbon/Toolbar in Query Design ... Quick Ribbon Access Bar - microsoft.public.word ... Access 2007 : How to hide ribbon ? - microsoft.public.access ...Hide ribbon event not working - microsoft.public.access.forms ... I'm terrible with VBA so this might be something really simple. In Access 2007, I have a startup form ... Ribbon idMso for TabHome? - microsoft.public.accessHide ribbon event not working - microsoft.public.access.forms ... Ribbon idMso for TabHome? - microsoft.public.access Hide ribbon event not working - microsoft.public ... Hide Ribbon - Show Print - microsoft.public.access.forms ...Hide ribbon event not working - microsoft.public.access.forms ... How to show a Customized Built-In Ribbon Tab When No Form is ... Hide Ribbon - Show Print - microsoft ... Get-ChildItem.Count not working with one file - microsoft.public ...Hide ribbon event not working - microsoft.public.access.forms ... Get-ChildItem.Count not working with one file - microsoft.public ... Word 2007 hide tracking changes not ... Reports and Ribbon Bar - microsoft.public.access.conversion ...Hide ribbon event not working - microsoft.public.access.forms ... Reports and Ribbon Bar - microsoft.public.access.conversion ..... Preview toolbar to your own toolbar, it ... Hiding Printing Dialog - microsoft.public.accessHide ribbon event not working - microsoft.public.access.forms ... Hiding Printing Dialog - microsoft.public.access How to hide notes pages? - microsoft.public.powerpoint ... Word 2007 hide tracking changes not working for me when Open File ...Hide ribbon event not working - microsoft.public.access.forms ... Word 2007 hide tracking changes not working for me when Open File ... Hide ribbon event not working ... Access Form event doesn't work and crashes Access - microsoft ...Hide ribbon event not working - microsoft.public.access.forms ... In Access 2007, I have a startup form with this event on load: Private Sub Form_Load ... and that works ... macro not working in Access 2007 in trusted location - microsoft ...Hide ribbon event not working - microsoft.public.access.forms ..... db is in a "trusted location," so events/macros ... ribbon event not working - microsoft.public ... Got Focus and Activate events not working - microsoft.public ...Hide ribbon event not working - microsoft.public.access.forms ... Got Focus and Activate events not working - microsoft.public ... Got Focus and Activate events not ... navigation pane and ribbon - microsoft.public.access.formscoding ...Hide ribbon event not working - microsoft.public.access.forms ... I got the code from searching for ways to hide the ribbon and navigation pane. Show/hide is showing although the button isn't selected- word ...Word 2007 spellcheck isn't working - microsoft.public.word ... Show/hide is showing although the button isn't selected- word ... Hide ribbon event not working - microsoft ... Do.Cmd Close Not Working - microsoft.public.access.reports ...Hide ribbon event not working - microsoft.public.access.forms ... Hide ribbon event not working - microsoft.public.access.forms ... DoCmd.RunCommand acCmdWindowHide DoCmd ... How can I get back a missing Excel ribbon? - microsoft.public ...I'm using Windows Vista, and my ribbon will not come up, unless I open Excel in the ... Excel 2007 - Excel 2007 Ribbon - Hide the Ribbon in Excel 2007 In Excel 2007 the ... Query Builder In the Instant Search pane is not working ...Hide ribbon event not working ... the Navigation Bar task pane where you can add ... ... caution in allowing users to see the query builder ... Problem in making changes within a report's Detail_Format event FollowHide ribbon event not working - microsoft.public.access.forms ... I also tried making a custom ribbon and ... hide label in subreport within report - microsoft ... case ... Hide ribbon event not working DataBase - DataBase Discussion List ...I am terrible with VBA so this might be something really simple. In Access 2007, I have a startup form with this event on load: Private Sub Form_Load() Hide ribbon event not working - microsoft.public.access.forms ...I'm terrible with VBA so this might be something really simple. In Access 2007, I have a startup form with this event on load: Private Sub Form_L... Answer : Hide ribbon event not working - GNT : your source for ...Hide ribbon event not working - answer - I'm terrible with VBA so this might be something really simple. In Access 2007, I have a startup form with this event on load ... Hide ribbon event not working [Form] - Adras.com - Solutions for ...I'm terrible with VBA so this might be something really simple. In Access 2007, I have a startup form with this event on load: Private Sub Form_Load() DoCmd ... Re: Hide ribbon event not working - Tech-Archive.net: The source ...Hi, Hide Ribbon and menus: DoCmd.ShowToolbar "Ribbon", acToolbarNo Show Ribbon and menus: DoCmd.ShowToolbar "Ribbon", acToolbarYes Hide navigaionpanel: Hide ribbon event not working - Tech-Archive.net: The source for ...I'm terrible with VBA so this might be something really simple. In Access 2007, I have a startup form with this event on load: Private Sub Form_Load() Hide ribbon event not working - PC Review - Computer News and ReviewsI'm terrible with VBA so this might be something really simple. In Access 2007, I have a startup form with this event on load: Private Sub Form_Load() Excel 2007 - Excel 2007 Ribbon - Hide the Ribbon in Excel 2007To Hide the Ribbon Commands: Double click on one of the ribbon tabs - such as Home, ... News & Events; Work at About; SiteMap; All Topics; Reprints; Help; Write for About; User Agreement Hide or Display Ribbon Tab/Group/Control with getVisibleMyTag = "show" in the Workbook_Open event in the ... Because getVisible is not working for Built-in Tabs ... in this file use startFromScratch = true to hide the Ribbon ... Working with the SharePoint 2010 Ribbon User InterfaceWorking with the SharePoint 2010 Ribbon User Interface ... the button shows up on the ribbon, however, the image is not ... Responding to postback event from ribbon.</p 7/24/2012 1:44:32 AM
|