I'm trying to update the ribbons in MS Access 2007. I migrated a database from 2003 to 2007. In the ribbon I created it seems that the "delete" button doesn't work. I think one can adjust it in the VBA code, and I'm not sure what code I'll include. This is so far what I've got in my XML:
<button idMso="Delete" label="Löschen" size="large" />
Does anyone have any idea how to have the "delete" button works?
Further details:
http://picasaweb.google.com/tintincutes/UnbenanntesAlbum#5415113558232954946
In my basRibbonCallbacks here is what I got:
Sub OnActionButton(control As IRibbonControl)
Select Case control.Id
Case "btnOpenFormular"
DoCmd.OpenForm "FormName"
Case "btnCloseFrmEingabe"
DoCmd.Close acReport
Case "btnDelete"
DoCmd.DoMenuItem acFormBar, acEditMenu, 8, , acMenuVer70
DoCmd.DoMenuItem acFormBar, acEditMenu, 6, , acMenuVer70
End Select
End Sub
In the Case "btnDelete" I'm not really sure what to put here. I can see the "delete button" is not already grayed out but if I select a record on my form and click delete nothing happens. Is the code correct? Thanks
And in my USysRibbons the XML code I got is this:
<?xml version="1.0" encoding="windows-1252"?>
<customUI xmlns="http://schemas.microsoft.com/office/2006/01/customui">
<ribbon startFromScratch="true">
<tabs> <tab id="tab2" label="Overview" insertAfterMso="TabDatabaseTools">
<group id="Group3" label="Navigation">
<button id="btnDelete" label="Löschen"
imageMso="RecordsDeleteRecord" size="large"
onAction="OnActionButton" />
</group>
</tab>
</tabs>
</ribbon>
</customUI>