Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8231911
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T17:39:07+00:00 2026-06-07T17:39:07+00:00

I have created an access 2010 form where I have a listbox and two

  • 0

I have created an access 2010 form where I have a listbox and two command buttons. Listbox includes all of the query names and command button one is for “query print preview” and the command button 2 is for “opening the query” which should be same as “double clicking the query name” in the listbox. So, how do I make these buttons and queries to open when double clicked in the list work?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T17:39:08+00:00Added an answer on June 7, 2026 at 5:39 pm

    Edit: I’ve updated my answer with the generic code you would need to open a query via the button or the Listbox. This assumes that the values in the Listbox are valid query names within your database.

    This is easily done with a little VBA.

    Option Explicit
    Private Sub List_DblClick(Cancel As Integer)
    Call Show_Click
    End Sub
    
    Private Sub Show_Click()
    DoCmd.OpenQuery Me.List.Value
    End Sub
    

    This assumes that your listbox is called List. And your command button is called Show.

    Basically, the code you want run in the button’s Click event and call that sub from the list box’s DblClick event.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have created a form in access 2010, in which there is a show
I have two tables in a 2010 Access Database. One for Customers and One
I have created application where i just need to access data form assets folder.
I have created a dozen different charts using the chart form wizard in Access
I have created one aspx Page from that i need to access the property
I have a form in MS access. I have created a few textboxs in
I am using MS Access 2010 and I already have sharepoint linked table created
I have created an MS Access 2003 application, set up as a split front-end/back-end
I have created a Data Access Layer using .NET. Everywhere that I update a
I have created a Java web service and I am trying to access this

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.