Results 1 to 5 of 5
  1. #1
    GraeagleBill's Avatar
    GraeagleBill is offline Experienced Old Geezer
    Windows 7 64bit Access 2003
    Join Date
    Feb 2011
    Posts
    1,919

    Control visibility on continuous form

    Below is a snippet of a screenshot taken from a continuous form where I'm wanting to use Allen Browne's calendar form. What I'd like is to ONLY have the calendar command button visible when either the "Date of Entry" text box is null, like you see on the "new record entry line, OR where a record has the focus. As you can see from the screenshot, the command button is visible for all records.

    Click image for larger version. 

Name:	DOE.jpg 
Views:	11 
Size:	102.1 KB 
ID:	19133

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,921
    Can't do this on Continuous form. Setting properties of control on continuous form affects ALL instances of the control. There is, after all, only one button control. Conditional Formatting can be used on textboxes to manage colors and Enabled property but aside from that, cannot individually set properties for each record.

    Put calendar button in the form header and manage its properties with code in form Current event.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    GraeagleBill's Avatar
    GraeagleBill is offline Experienced Old Geezer
    Windows 7 64bit Access 2003
    Join Date
    Feb 2011
    Posts
    1,919
    Hi June,

    Happy New Year!

    I was expecting an answer similar to what you've offered. I think I'll just be satisfied to use the OnGotFocus and OnLostFocus events of the DOE text box to toggle the visibility of the calendar's command button when "DOE's" have or loose the focus, but as you say, that then applies to all the records.

    Thanks,
    Bill

  4. #4
    GraeagleBill's Avatar
    GraeagleBill is offline Experienced Old Geezer
    Windows 7 64bit Access 2003
    Join Date
    Feb 2011
    Posts
    1,919
    I eliminated the command button and thereby any issues of visibility. Rather, I set the OnClick event of the DOE control to open the calendar. Sort of a DUH! Maybe had too much Christmas yesterday.

  5. #5
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,921
    I would probably use GotFocus or Enter event so users don't have to mouse click. But I have not explored the code behind this control. How is the calendar closed?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

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

Similar Threads

  1. Tag visibility using for loop on control
    By Ruegen in forum Programming
    Replies: 3
    Last Post: 11-13-2014, 04:08 PM
  2. Replies: 2
    Last Post: 09-25-2014, 11:24 AM
  3. Replies: 8
    Last Post: 05-23-2014, 02:19 PM
  4. Calculated control on Continuous Form
    By Mtyetti2 in forum Forms
    Replies: 2
    Last Post: 03-25-2013, 05:13 PM
  5. Dlookup as control source on continuous form.
    By Ramun_Flame in forum Programming
    Replies: 4
    Last Post: 10-24-2012, 10:26 AM

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