Results 1 to 2 of 2
  1. #1
    pdevito3 is offline Advanced Beginner
    Windows 7 64bit Access 2010 64bit
    Join Date
    Aug 2013
    Posts
    35

    Dynamic Defualt Values on Tables

    Hi everyone,



    Does anyone know if it is possible to have a dynamic default value for a text field on a table? For example:

    I have a list of 10 items in my "Name" field called W-1,W-2,W-3,...W-10. I want the next field to automatically say W-11 and the field after that to say W-12, etc.

    It might be worth noting that I can not use my primary key as reference, because it will not always match the "W-" value.

    Thanks in advance!

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 7 64bit Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,930
    You want to create custom unique ID. That requires code. This is a common topic. Search forum. You could have code in the record BeforeUpdate event set the DefaultValue property. Would also need code in the form Open event to set the starting value. Be careful, generating unique ID by code is risky with multiple users.
    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: 22
    Last Post: 05-31-2013, 09:13 AM
  2. Replies: 11
    Last Post: 08-31-2012, 12:24 AM
  3. To set a defualt value for a query input
    By mercapto in forum Queries
    Replies: 1
    Last Post: 06-06-2012, 09:54 AM
  4. Dynamic Check Boxes values from table
    By ktmjamal in forum Forms
    Replies: 1
    Last Post: 02-21-2011, 07:49 AM
  5. Replies: 8
    Last Post: 05-25-2010, 04:50 AM

Tags for this Thread

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