Results 1 to 8 of 8
  1. #1
    redbull's Avatar
    redbull is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2012
    Location
    Missouri
    Posts
    480

    Text box showing #name?

    I am trying to display a record on a form. So I have a form with alot of text boxes... I changed the control source using the wizard...
    =[QueryName]![ColumnIwant]


    But while in form view, the text box shows #Name? .... I am certain that it is a small detail I missed along the way, any recommendations?

  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,632
    Try not using the query name.

    I don't use the wizards. They confuse me more than help.
    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
    redbull's Avatar
    redbull is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2012
    Location
    Missouri
    Posts
    480
    So should I run a make table query? I ussually try to avoid the wizards as well, but I am facing one MONSTER of a deadline and I thought it would be quicker... Boy was I mistaken. I am horrible at access stuff, but fairly solid at vba.. Would it be easier to use vba?

  4. #4
    Missinglinq's Avatar
    Missinglinq is offline VIP
    Windows 7 64bit Access 2007
    Join Date
    May 2012
    Location
    Richmond (Virginia, not North Yorkshire!)
    Posts
    3,018
    What is the RecordSource of the Form? Is ColumnIwant a Field in that Table/Query?

    If the answer to the second question is 'Yes,' you simply select the Control and go to Property - Data and select the Field from its dropdown box.

    If the answer is 'No,' you'll need to use the DLookup() Function to retrieve the data.

    Linq ;0)>

  5. #5
    redbull's Avatar
    redbull is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2012
    Location
    Missouri
    Posts
    480
    There is no recordsource of the form, it's blank. I just tried making the recordsource the query I want, but then I lost all my text boxes and such... So I removed that.

    ColumnIwant is a field on the query.

    SO now knowing that I will have to use the Dloopup function, I have been playing with that syntax and I can't get it to retrieve what I want.

  6. #6
    redbull's Avatar
    redbull is offline Competent Performer
    Windows XP Access 2003
    Join Date
    Mar 2012
    Location
    Missouri
    Posts
    480
    GOT IT!, thank you both for you help!

  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,632
    Why not a bound form?

    If the form was not bound, setting RecordSource property should not 'lose' textboxes. I don't understand this.
    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
    Missinglinq's Avatar
    Missinglinq is offline VIP
    Windows 7 64bit Access 2007
    Join Date
    May 2012
    Location
    Richmond (Virginia, not North Yorkshire!)
    Posts
    3,018
    FYI, if you add a RecordSource and 'lose all your Textboxes,' it means that

    1. Your Form is Bound
    2. There are no Records in the RecordSource
    3. New Records cannot be added

    Only when all three of these things are true does this phenomenon occur.

    The reasons for #3, above, are numerous. The most common one is that the RecordSource is a Multi-Table Query that is Read-Only. For reasons why Multi-Table Querie that is Read-Only see Allen Browne's article:

    http://allenbrowne.com/ser-61.html

    Linq ;0)>

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

Similar Threads

  1. Replies: 2
    Last Post: 06-19-2013, 06:13 AM
  2. Replies: 1
    Last Post: 02-17-2012, 10:17 AM
  3. Showing Rich Text in Linked SQL Tables
    By EddieN1 in forum Access
    Replies: 0
    Last Post: 11-15-2011, 02:30 PM
  4. #Name? error showing in Text box.
    By yes sir in forum Access
    Replies: 2
    Last Post: 09-21-2010, 02:25 PM
  5. Replies: 2
    Last Post: 04-29-2009, 11:50 AM

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