Results 1 to 9 of 9
  1. #1
    Ashley25 is offline Novice
    Windows 7 64bit Access 2013
    Join Date
    Aug 2014
    Posts
    12

    Auto-population

    Hello,



    I'm trying to figure out a way to get my access database to auto-populate data into a field based on the information I type into the first record.

    So what I'm looking to do is that when I type a name into the UserName Field it will automatically fill in the rest of the field with the same information.

    Click image for larger version. 

Name:	Capture1.PNG 
Views:	9 
Size:	6.5 KB 
ID:	18003


    To clarify I'm looking for a way so that when I type something into one record it will fill the rest of the field in with that same information.

    I appreciate any help or advise you guys have to offer. Thank you for your time.

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,645
    What do you mean by 'rest of the field'? You want data to carry forward into subsequent records during data entry?
    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
    Ashley25 is offline Novice
    Windows 7 64bit Access 2013
    Join Date
    Aug 2014
    Posts
    12
    Yes. Is that possible?

  4. #4
    Ashley25 is offline Novice
    Windows 7 64bit Access 2013
    Join Date
    Aug 2014
    Posts
    12
    I know the whole 'Ctrl' + '"' trick but i just want it to automatically fill in without having to manually go through to fill in the records

  5. #5
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,645
    Yes. Use VBA code to set the DefaultValue property of each control you want value to carry forward.

    Review:
    http://access.mvps.org/access/forms/frm0012.htm
    http://allenbrowne.com/ser-24.html
    http://support.microsoft.com/kb/210236
    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.

  6. #6
    Ashley25 is offline Novice
    Windows 7 64bit Access 2013
    Join Date
    Aug 2014
    Posts
    12
    Those work great but not exactly what I was looking for. Those all seem to go if you already know the value you want to be carried through. What i'm looking for is more so if another user was filling in the information if they typed something in it would fill in the rest of the fields for them.

    So what i'm looking for is a code or an expression i can apply to my database so when i type in a name it will fill in that name in other records without having to put that name into the code or expression.

    Does that make sense?

  7. #7
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,645
    No, I do not understand. Your statements seem contradictory.

    Do you want to autopopulate fields of the same record based on name entered?

    Or do you want values entered in first record carried forward to subsequent new records in the same session?
    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.

  8. #8
    Ashley25 is offline Novice
    Windows 7 64bit Access 2013
    Join Date
    Aug 2014
    Posts
    12
    I want values entered in first record carried forward to subsequent new records in the same session.

  9. #9
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,645
    I have provided code examples for that.

    The code references the controls by name. The values in the referenced controls will be used to set the DefaultValue property.
    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. Auto population of foreign key
    By kattatonic1 in forum Forms
    Replies: 8
    Last Post: 10-23-2013, 11:04 AM
  2. Auto Population
    By gor in forum Access
    Replies: 4
    Last Post: 07-15-2012, 03:43 PM
  3. Auto population
    By Andyjones in forum Queries
    Replies: 5
    Last Post: 11-26-2011, 07:29 PM
  4. Form Auto population
    By Evgeny in forum Forms
    Replies: 28
    Last Post: 04-12-2010, 03:05 PM
  5. Form Auto population
    By Evgeny in forum Access
    Replies: 3
    Last Post: 04-08-2010, 05:17 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