[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

Access 2010 VBA Enable Right Click for Form Filter

Posted on 2013-05-16
5
Medium Priority
?
2,248 Views
Last Modified: 2013-05-24
I've developed an access database for a friend; I've attached a stripped down version to focus on the area.  In the past when making access databases, I've like to hide all of the ribbons and database window from the user.  I think it looks a little more professional and sometimes has security reasons (for those who are honest and just like to play around with things they are not supposed to) in doing so.

For this application, however, I need to make the right click available so that the user can filter the database values based on the form.   If you hold shift down while opening the database, which in this case I want to allow, the toolbars and database window appear, you can open the form, and you can right click on the "title" field of the form and filter the data.

If you just double-click the application icon opening the database, the user can not filter the data.  I have a macro in the background shutting down all of the toolbars and the database window.  I have no idea however to skip the functionality to allow the form filter in this process.  

I'm sure this is a fairly easy fix, but 3 days of googling and revising the VBA has not yet been successful.  I realize now that I should have just asked here.
rightclickenabledneeded.accdb
0
Comment
Question by:atljarman
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 53

Expert Comment

by:Rgonzo1971
ID: 39170861
0
 
LVL 74

Assisted Solution

by:Jeffrey Coachman
Jeffrey Coachman earned 800 total points
ID: 39171466
< In the past when making access databases, I've like to hide all of the ribbons and database window from the user.  I think it looks a little more professional and sometimes has security reasons (for those who are honest and just like to play around with things they are not supposed to) in doing so.
>
The kicker here is that the Access database has to run "inside" the Access environment.
So all of the techniques to "Hide the application Window" have equally complex consequences.

My guess is that when you "Hide" the Access application window, you lose the ability to filter...?

What I do is just:
Minimize the ribbon
Hide the Nave Pane
Disable Full menus

Or why not just create your own filter system and make it part of the form, then this should be a non-issue.
0
 
LVL 75
ID: 39172008
"For this application, however, I need to make the right click available so that the user can filter the database values based on the form. "

In A2010, you have two options (neither satisfactory):
1)  Create your own custom Right Click menu (aka context aka PopUps) via VBA code using the CommandBars collection)

2) Create custom menus (right click, menu & tool bars) in A2003 first - using the Customize Dialog, then Import these into A2010. Custom menus will show up on the Add-Ins Ribbon, and Right Click will show up normally.
I've created 1000's of custom menus/toolbars/popups with the Customize Dialog - soooooo eash.

There is *no* built in tool in A2010 to create Right Click menus OR custom Ribbons for that matter.

This is the de-facto standard tool for creating custom Ribbons:

http://www.ribboncreator2010.de

I have this tool
0
 

Accepted Solution

by:
atljarman earned 0 total points
ID: 39178365
This is the filter form that I created.  I really didn't want to add a ribbon as I wanted to hide the database window from the user during data entry.  

On the filter form, I uppercased both the value entered and the query value.  I also changed the recordsource of the main form to the query string created in VBA (dynamically) based on the values selected/entered by the user.

I've added the example in case others get to this page and they have the same issue.  Thanks for your suggestions.
rightclickenabledneeded.accdb
0
 

Author Closing Comment

by:atljarman
ID: 39193688
Good ideas provided, but a working solution made available in the end so other users can download and repeat for their purposes as needed.
0

Featured Post

Prepare for your VMware VCP6-DCV exam.

Josh Coen and Jason Langer have prepared the latest edition of VCP study guide. Both authors have been working in the IT field for more than a decade, and both hold VMware certifications. This 163-page guide covers all 10 of the exam blueprint sections.

Question has a verified solution.

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

The Windows Phone Theme Colours is a tight, powerful, and well balanced palette. This tiny Access application makes it a snap to select and pick a value. And it doubles as an intro to implementing WithEvents, one of Access' hidden gems.
This article will show how Aten was able to supply easy management and control for Artear's video walls and wide range display configurations of their newsroom.
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
Suggested Courses

649 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