Results 1 to 4 of 4
  1. #1
    Join Date
    May 2012
    Posts
    13

    How to show field content in a Label?

    Hi,

    I am new to access programming although I have some experience with VBA.

    I am wondering how to do the following: I want to display the ID of a dataset in a form but I donīt want the user to be able to edit it. Therefore I want to display the id in a label and not a textbox or combo etc.



    I canīt see a way of how to do this though. Is this possible, or am I going about it the wrong way?

    yours,

    Rob

  2. #2
    R_Badger is offline Knows a few tricks
    Windows XP Access 2003
    Join Date
    Feb 2012
    Location
    Suffolk, UK
    Posts
    262
    You could just use a text box and set the property 'locked' to yes

  3. #3
    Join Date
    May 2012
    Posts
    13
    Thanks.

    Is this the normal way of doing things then? Do you know if it is possible to do what I described or not?

  4. #4
    R_Badger is offline Knows a few tricks
    Windows XP Access 2003
    Join Date
    Feb 2012
    Location
    Suffolk, UK
    Posts
    262
    That's the way I would do it, if it is 'data' and I don't want the user to edit it.

    I don't know why you would want to do it another way as pretty much every other way is harder or at least requires some thought!

    If you are desperate to assign the value to a label (I feel the need to say again I cannot see any possible gain from doing this over simply locking the control) then you can go through the vba route, of assigning the caption on the oncurrent event.

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

Similar Threads

  1. Show all content in one field
    By Tecch82 in forum Database Design
    Replies: 4
    Last Post: 04-06-2012, 12:05 PM
  2. Hide the content of a field
    By peter_lawton in forum Queries
    Replies: 6
    Last Post: 01-17-2012, 11:24 AM
  3. Show label on report only if data in field
    By senna in forum Reports
    Replies: 1
    Last Post: 01-31-2011, 06:11 AM
  4. update field with specific content
    By luxeon in forum Queries
    Replies: 2
    Last Post: 01-24-2011, 03:29 PM
  5. Field content based on date calculation
    By jlmnjem in forum Programming
    Replies: 6
    Last Post: 09-23-2010, 10:24 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