Results 1 to 4 of 4
  1. #1
    TIG_Slayer is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Jul 2014
    Posts
    11

    Option Group Issue

    Hello Forum!

    I have a quick question, possibly an easy fix. I currently have a form with an option group with 3 options that have VBA behind them to export certain reports to Excel.

    My issue is, that when this form is opened and I select the report to export, and then click the option button, it always runs the second option, no matter which I click. Then after that option executes, I can go back and click the first or third and they will run fine. So this only happens when the form is first opened.



    I checked the default values for the option group and it is blank, so i'm thinking it may be an issue since I am running the code when the buttons getfocus?

    Any help is greatly appreciated, and if you think something else would perform better, I am open to suggestions also.

    Thanks, TIG.

    EDIT- Below is a screenshot of what my form looks like.

    Click image for larger version. 

Name:	ItemlistPopup.JPG 
Views:	9 
Size:	31.2 KB 
ID:	18551

  2. #2
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,525
    Yes set the default value in the frame
    and make sure each button also has different value.

  3. #3
    TIG_Slayer is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Jul 2014
    Posts
    11
    Quote Originally Posted by ranman256 View Post
    Yes set the default value in the frame
    and make sure each button also has different value.
    What should I set the default value to? Once one of the options are clicked, it executes. So if I set the default value to 1, it would execute my first option automatically, which I don't want to happen.
    Thanks for the quick reply.
    TIG

  4. #4
    ranman256's Avatar
    ranman256 is offline VIP
    Windows Vista Access 2010 32bit
    Join Date
    Apr 2014
    Location
    Kentucky
    Posts
    9,525
    You shouldnt execute upon option pick. Accidents happen
    you need a button so the user is SURE of the option.
    set the frame.value to default.
    Last edited by ranman256; 10-30-2014 at 02:23 PM.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. option group
    By Sheba in forum Forms
    Replies: 25
    Last Post: 10-21-2014, 02:38 PM
  2. Replies: 4
    Last Post: 10-03-2014, 06:36 AM
  3. Option Group Question
    By chef6886 in forum Programming
    Replies: 4
    Last Post: 01-18-2013, 09:10 PM
  4. Option Group
    By x__hoE__x in forum Access
    Replies: 2
    Last Post: 12-10-2011, 09:39 AM
  5. Option Group
    By huskies in forum Forms
    Replies: 9
    Last Post: 12-02-2009, 12:06 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums