Solved

Access 2007 filter/sort arrow in datasheet

Posted on 2009-03-31
9
456 Views
Last Modified: 2012-08-14
Hi Experts

In 2007 they have included a new function to the coloums in a datasheet. It's an arrow that can sort and filter. But I would like to remove it, permenatly. Can I do it with VBA code?
0
Comment
Question by:DCRAPACCESS
  • 4
  • 3
  • 2
9 Comments
 
LVL 28

Expert Comment

by:TextReport
ID: 24027437
This is controlled by the ShortCutMenu property of the form, set it to NO.
Cheers, Andrew
0
 
LVL 65

Expert Comment

by:rockiroads
ID: 24027499
From what Andrew says, this faq confirms it http://accessjunkie.com/faq_53.aspx
Any reason why you would want to do it in vba?
0
 

Author Comment

by:DCRAPACCESS
ID: 24027544
What if the database are used in both 2003 and 2007. What will that do to the settings? That is why i would like to control it i VBA, to be sure that it's turn off in 2007.
0
 
LVL 65

Expert Comment

by:rockiroads
ID: 24027557
shortcut menu switched off in 2003 will merely do nothing when you right click on the form
0
U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

 
LVL 65

Expert Comment

by:rockiroads
ID: 24027562
in vba, you can try this to switch it off

me.shortcutmenu = false

0
 
LVL 65

Expert Comment

by:rockiroads
ID: 24027574
Mind you, that code works fine in 2003 but not in 2007
0
 
LVL 28

Accepted Solution

by:
TextReport earned 500 total points
ID: 24027593
The problem is that it will also disable the built-in Shortcut Menubar, the problem is by the time the OnOpen is executed you can turn off the Shortcut menu and it does disble the Shortcut menu but not the dropdown.
Cheers, Andrew

PS You could reverse the logic to see if turning it OFF by default and enabling in previous versions would work.
Private Sub Form_Open(Cancel As Integer)

    If SysCmd(acSysCmdAccessVer) >= "12.0" Then

       Me.ShortcutMenu = False

    End If

End Sub

Open in new window

0
 
LVL 28

Expert Comment

by:TextReport
ID: 24027612
Heres the reverse logic. Just though you may get a string comparison here so v9 would be after v10
Cheers, Andrew
Private Sub Form_Open(Cancel As Integer)

    If Val(SysCmd(acSysCmdAccessVer)) < 12 Then

       Me.ShortcutMenu = True

    End If

End Sub

Open in new window

0
 

Author Comment

by:DCRAPACCESS
ID: 24027623
Thanks! Just what I was looking for.
0

Featured Post

Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Overview: This article:       (a) explains one principle method to cross-reference invoice items in Quickbooks®       (b) explores the reasons one might need to cross-reference invoice items       (c) provides a sample process for creating a M…
I see at least one EE question a week that pertains to using temporary tables in MS Access.  But surprisingly, I was unable to find a single article devoted solely to this topic. I don’t intend to describe all of the uses of temporary tables in t…
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
Using Microsoft Access, learn some simple rules for how to construct tables in a relational database. Split up all multi-value fields into single values: Split up fields that belong to other things into separate tables: Make sure that all record…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now