Results 1 to 4 of 4
  1. #1
    161 is offline L33t N00b
    Windows 2K Access 2003
    Join Date
    Dec 2010
    Posts
    33

    Referencing a form in a subform

    Hello, and thank you for checking out my post.



    I currently have a form (which I use to input data into my tables)
    Next to it, I have a subform, which uses a few simple dlookup functions to spit out some important end-result values as a FYI to the user.

    It is reporting the correct values for the first entry in the form, however I want it to update as I scroll through different entries. Does anyone have any ideas how to "refresh" the subform every time I go to a new entry? Is there a way to reference the "currently being viewed" entry on the form?

  2. #2
    ajetrumpet is offline VIP
    Windows Vista Access 2007
    Join Date
    Mar 2010
    Location
    N/A
    Posts
    2,694
    use the "current" event. and if needed, check for "me.newrecord". that's not necessary, as the current event only runs once (I think), right when you request it.

    do you still want to know how to reference a control on the main form? you do it like so (in code):
    Code:
    me.parent.controlname

  3. #3
    161 is offline L33t N00b
    Windows 2K Access 2003
    Join Date
    Dec 2010
    Posts
    33
    I'm currently using the "currentevent" under the property tab of the subform, to re-open the subform every time I go to a new entry. It seems to re-open, but the subform re-opens to the first entry each time. Any ideas how I can make this variable with the data open in the main form?

  4. #4
    ajetrumpet is offline VIP
    Windows Vista Access 2007
    Join Date
    Mar 2010
    Location
    N/A
    Posts
    2,694
    Quote Originally Posted by 161 View Post
    I'm currently using the "currentevent" under the property tab of the subform, to re-open the subform every time I go to a new entry. It seems to re-open, but the subform re-opens to the first entry each time. Any ideas how I can make this variable with the data open in the main form?
    whats the code

    and there is no such thing as "reopening". don't know what you mean really

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

Similar Threads

  1. referencing subform entry in selection query
    By Pielewuiter in forum Forms
    Replies: 22
    Last Post: 11-20-2010, 01:58 PM
  2. Referencing split form data / filter
    By stephenaa5 in forum Programming
    Replies: 2
    Last Post: 09-14-2010, 08:48 AM
  3. Referencing A Form Field In A Report
    By CGM3 in forum Reports
    Replies: 5
    Last Post: 07-01-2010, 08:16 PM
  4. Replies: 0
    Last Post: 12-08-2009, 01:19 PM
  5. referencing each record
    By grgerhard in forum Forms
    Replies: 1
    Last Post: 11-11-2006, 08:15 PM

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