Results 1 to 3 of 3
  1. #1
    Join Date
    Jan 2004
    Location
    Philippines
    Posts
    30

    Exclamation Unanswered: help with expressions

    Hi guys I hope you can help me out. I have 2 main forms ('main' and 'processing') that share a common form ('unverified'). The 'main' form manipulates data in the 'main' table while the 'processing form' manipulates data in the 'processing' table. When I click the update button on either of the main forms, the form 'unverified' pops up. The function of this form is to update records that are unverified in both tables. I was able to do the updating part. However, I am having trouble with the requerying part. On both main forms, there are subforms with different names. I want to requery them when I close the 'unverified' form so I can see the changes made by the updates. The trouble is, I am having a hard time coming up with a macro or expression to do this because I only work with one main form at a time. Is there a way to run a requery on a control on a different form even if one of the main forms is closed while the other is open? I hope you guys understand my explanation Well, I could just place a macro in the On Got Focus property of the main forms that tells them to requery themselves right? But I am curious if this can be done with expressions or conditions (I'm dumb when it comes to this). Likewise, can you guys give me some tips on how I can learn writing visual basic expressions (like books to read or sites to visit)? Thanks a lot!!!
    pao_pao3

  2. #2
    Join Date
    Mar 2003
    Location
    The Bottom of The Barrel
    Posts
    6,102
    Provided Answers: 1
    I'm not sure if you can do it with a macro or not as I don't use them often, but you can requery controls on other forms through: forms!yourForm!yourControl.requery
    oh yeah... documentation... I have heard of that.

    *** What Do You Want In The MS Access Forum? ***

  3. #3
    Join Date
    Jan 2004
    Location
    Philippines
    Posts
    30

    Talking Thanks for the suggestion!

    Thanks! I suppose you place this code using the Code Builder. But I did use a macro to requery the subforms instead. However, I will try to apply this particular code as it might run faster than using a macro. Thanks again
    pao_pao3

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •