Results 1 to 4 of 4
  1. #1
    snoopy2003 is offline Advanced Beginner
    Windows 7 64bit Access 2010 32bit
    Join Date
    Feb 2011
    Posts
    72

    Goto a new record in tabbed subform

    Hello,

    I have a form (frmWorker) with tabbed subform within it (subfrmPayments)
    (I created a tabbed form and added it as subform to a form).
    Each tab is a continues form.


    I wish each tab to display all the records and goto new record line.
    In the On_Load event of the main form, I tried to focus on a field in the tabbed subform from the main form, but it didn't work.

    If Forms!frmWoker!subfrmPayments!subfrmPayType1.Form. RecordsetClone.RecordCount > 0 Then
    Forms!frmWoker!subfrmPayments!subfrmPayType1.SetFo cus
    Forms!frmWoker!subfrmPayments!subfrmPayType1.Form! Amount.SetFocus
    DoCmd.RunCommand acCmdRecordsGoToNew
    End If

    Can you help me ?

  2. #2
    djoosten is offline Novice
    Windows XP Access 2003
    Join Date
    Mar 2011
    Location
    Wisconsin
    Posts
    7
    Try moving your code to the On_Current event of the Main Form. I don't think it is able to synchronize the sub-form since the Main forms record has not been established. Just my quick thoughts.

  3. #3
    ajetrumpet is offline VIP
    Windows Vista Access 2007
    Join Date
    Mar 2010
    Location
    N/A
    Posts
    2,694
    Quote Originally Posted by djoosten View Post
    Try moving your code to the On_Current event of the Main Form. I don't think it is able to synchronize the sub-form since the Main forms record has not been established. Just my quick thoughts.
    that will not do it on it's own. this is, unfortunately too complex to figure out on your own if you're a newbie. snoopy, take a look at this: http://www.access-programmers.co.uk/...d.php?t=145533

    In that thread, I cover most of what you're going to need. the syntax that's needed can also be found there. good luck, bud!

  4. #4
    snoopy2003 is offline Advanced Beginner
    Windows 7 64bit Access 2010 32bit
    Join Date
    Feb 2011
    Posts
    72
    Thank you for your help.
    It is a helpful link with clear and excellent explanation.
    I tried to figure how to write it correct for the whole night with no success.

    Now, Its clear.


    Thank you

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

Similar Threads

  1. Tabbed SubForm Issues
    By Exwarrior187 in forum Forms
    Replies: 5
    Last Post: 03-01-2011, 11:04 AM
  2. Customize button "goto last record"
    By bertenbert in forum Forms
    Replies: 1
    Last Post: 12-30-2010, 08:38 AM
  3. Replies: 1
    Last Post: 12-22-2010, 01:28 AM
  4. Replies: 7
    Last Post: 12-13-2010, 03:12 PM
  5. Replies: 5
    Last Post: 06-29-2010, 01:24 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