Results 1 to 2 of 2
  1. #1
    ksor's Avatar
    ksor is offline Competent Performer
    Windows 10 Access 2010 32bit
    Join Date
    Feb 2017
    Posts
    126

    Referencing fields in a continuous form ??

    I use MS Office 365 Home version and I need to reference a date field in a continous sub form of some persons each with a birthdates in a column of the continous form.



    In the immidiate windows I can get the FIRST (a row) of these birthdates with this:

    "PERSON Vedligehold af" is the name of the main form,
    and
    "Sub Form BØRN til en forælder" is the name of the sub form on a TAB

    ? Forms("PERSON Vedligehold af").Controls("Sub Form BØRN til en forælder").Controls("Dato for forældreskabet")

    06-02-1932



    and that date IS IN FACT the birthdate of THE PERSON in THE FIRST ROW !

    This works too, but still ONLY from the first ROW:

    ? FORMS![PERSON Vedligehold af]![Sub Form BØRN til en forælder].FORM.[FSDato]
    But how do I reference the NEXT PERSONS birthdate - the person in the next rows 2, 3, ... ?

    (I have tried to use the generator, but oh my ... it's so messy and it ends up with some code, that can't be executed without errors)

    EDIT: Where is the screendump ??????

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,901
    That code should return value from whatever record has the focus.

    What exactly are you trying to accomplish? Why do you need to pull birthdate?


    Don't know why your image attachment failed.
    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. Replies: 3
    Last Post: 12-28-2015, 04:11 PM
  2. Replies: 18
    Last Post: 05-07-2015, 10:59 AM
  3. Referencing form fields with a string variable
    By ts_hunter in forum Programming
    Replies: 3
    Last Post: 02-13-2014, 01:06 PM
  4. Replies: 5
    Last Post: 06-24-2013, 04:54 PM
  5. Populating a Continuous Form with Unbound Fields
    By gazzieh in forum Programming
    Replies: 6
    Last Post: 02-28-2013, 11:11 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