XML code for ribbon (1 Viewer)

UnrulyJulie

Registered User.
Local time
Today, 10:49
Joined
Jan 29, 2010
Messages
62
There's something wrong with this xml - can someone please help?? The only control that is showing is the Print- Tabs appear, group appears, but the controls are not...

<customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui">
<ribbon startFromScratch="true">
<tabs>
<tab id="dbCustomTab1" label="Export Tools">
<group id="dbCustomGroup1" label="Options" visible="true">
<control idMso="ExportExcel" enabled="true"/>
<control idMso="ExportSavedExports" enabled="true"/>
<control idMso="ExportWord" enabled="true"/>
<control idMso="ExportTextFile" enabled="true"/>
<control idMso="PrintDialogAccess" enabled="true"/>
</group>
</tab>
<tab id="tabHome" label="Home">
<group id="grpData" label="Navigation" visible="true">
<button id="CloseForm" label="Close Datasheet" imageMso="FileExit"
size="large" onAction="=CloseForm(InventoryTempDataExport)" />
</group>
</tab>
</tabs>

<contextualTabs>
<tabSet idMso="TabSetFormDatasheet" visible="false">
</tabSet>
</contextualTabs>

</ribbon>
</customUI>
 
Last edited:

UnrulyJulie

Registered User.
Local time
Today, 10:49
Joined
Jan 29, 2010
Messages
62
Forgot to mention - I am using Access 2013. This xml worked just fine in 2010.
 

vbaInet

AWF VIP
Local time
Today, 15:49
Joined
Jan 22, 2010
Messages
26,374
I'm a bit rusty on ribbons because I've not touched Access for a while and I don't use Access 2013 but if it works in 10 and not in 13 I think the namespace is incorrect so try changing this:
Code:
<customUI xmlns="http://schemas.microsoft.com/office/[COLOR="Red"]2009/07[/COLOR]/customui">
to this:
Code:
<customUI xmlns="http://schemas.microsoft.com/office/[COLOR="Blue"]2006/01[/COLOR]/customui">
 

UnrulyJulie

Registered User.
Local time
Today, 10:49
Joined
Jan 29, 2010
Messages
62
No, that didn't work. But I think I am narrowing the issue.

If I open the form using the custom ribbon directly, the custom ribbon works fine. But if I go through the user's route :

Main Form-->Inventory Form-->Reports Button-->Data Export Button

The ribbon does not appear correctly! What would cause that?
 

vbaInet

AWF VIP
Local time
Today, 15:49
Joined
Jan 22, 2010
Messages
26,374
What do you mean by "it doesn't appear correctly"?
And what form does Data Export Button open exactly?
 

UnrulyJulie

Registered User.
Local time
Today, 10:49
Joined
Jan 29, 2010
Messages
62
When I click on the form InventoryTempDataExport from the navigation pane to open it, the ribbon appears correctly as written with the code I posted.

When I go through the forms to get to the report, and click on the button (InventoryTempExportButton) to open the report called InventoryTempDataExport, the ribbon does not appear correctly. I have attached the differences.

There is an embedded macro on the button to call the report (datasheet view).

I attached screenshots of the correct/incorrect ribbons.
 

Attachments

  • incorrect.PNG
    incorrect.PNG
    2.6 KB · Views: 111
  • correct.PNG
    correct.PNG
    4.4 KB · Views: 124

vbaInet

AWF VIP
Local time
Today, 15:49
Joined
Jan 22, 2010
Messages
26,374
It could mean that one of the callbacks is making it hidden or the form is embedded in a subform that doesn't have the full ribbon or even some of the idMso are invalid. Hard to say because I don't know ho without seeing the db.

Go behind the Data Export button and see what form it's opening exactly.
 

UnrulyJulie

Registered User.
Local time
Today, 10:49
Joined
Jan 29, 2010
Messages
62
I named the report in my previous post - it is the same report.
 

UnrulyJulie

Registered User.
Local time
Today, 10:49
Joined
Jan 29, 2010
Messages
62
Embedded Macro:

OpenForm InventoryTempDataExport

View - Datasheet
Filter Name (blank)
Where Condition (blank)
Data Mode - Read Only
Window Mode - Normal
 

vbaInet

AWF VIP
Local time
Today, 15:49
Joined
Jan 22, 2010
Messages
26,374
Nothing suspicious there.

Upload a test db let me see if I can replicate the problem on my 2010 version. I just need the forms and macro, no tables/queries/reports or other code.
 

UnrulyJulie

Registered User.
Local time
Today, 10:49
Joined
Jan 29, 2010
Messages
62
God morning - ok, felt I had to include a few tables and the query behind the form, as they don't operate correctly (from a user standpoint) without them. I did limit the tables to just a few records (there are over 50K in the db).

Running through the forms, the ribbon works fine in this test. So I have to assume there is something in the form the user accesses prior to the two attached that is causing the problem. Sadly, those forms are more involved and would be difficult to add to this db without a lot of other tables.
 

Attachments

  • test-ribbon.zip
    59.5 KB · Views: 160

vbaInet

AWF VIP
Local time
Today, 15:49
Joined
Jan 22, 2010
Messages
26,374
What options do I select to open the form from the other form?
 

UnrulyJulie

Registered User.
Local time
Today, 10:49
Joined
Jan 29, 2010
Messages
62
Open the Inventory Report Options form, then Active Inventory Data Export button towards the bottom on that form.
 

vbaInet

AWF VIP
Local time
Today, 15:49
Joined
Jan 22, 2010
Messages
26,374
I can't see anything obviously wrong with the ribbon itself because it's loading file. Did you turn on error reporting for the ribbon?

Maybe ask your colleague, he may have changed something (again)!
 

vbaInet

AWF VIP
Local time
Today, 15:49
Joined
Jan 22, 2010
Messages
26,374
There's nothing that can't be solved or at the very least come up with a workaround. Did you put on the error handling for the ribbon though? And have you tried it on another machine?
 

UnrulyJulie

Registered User.
Local time
Today, 10:49
Joined
Jan 29, 2010
Messages
62
There are no errors. I have the same result on another machine. This has something to do with the code that exists for the forms that are accessed by the user preceding the button macro to open the datasheet view form in question. Still trying to wade through it, but doesn't seem to make sense.
 

vbaInet

AWF VIP
Local time
Today, 15:49
Joined
Jan 22, 2010
Messages
26,374
I can't see anything off with the ribbon's XML. If I had 2013 it would make more sense. By the way, is there any other ribbon in your db that looks exactly as that?
 

Users who are viewing this thread

Top Bottom