Results 1 to 4 of 4
  1. #1
    sparkyinak is offline Novice
    Windows 10 Access 2016
    Join Date
    Mar 2019
    Posts
    22

    issues with assigning control souce to undounded text box

    I am missing something obvious apparently. My database (MeDBTable)has an editable drop box for city (MeCityField). On a data entry form (MeEntryForm)has a city field that’s a drop box as well so if the name of the city (MeCityField) is not part of the default list, it can be saved for future use and plugs the new city data in the database where it belongs. It works great.



    My 2
    nd
    form is basically a copy and paste of the MeEntryFormwith a couple minor variations that is used just for Sorting and filteringdata. I’ll call this form MeFilterForm. I recently learned while playing with theFilter by Form option that I am not able to filter data in the MeCityField. Figuring that being a drop box and don’t really need a drop box on MeFilterForm, I would replace it with a text box which I know I can filter through Filter by Form option.


    I put in an unbound text box in the MeFilterForm and set it’s control source as =[MeDBTable]![MeCityField]. I click ok, close, and save the form. When I open the form, I get the “#Name?” error. When I go in to Filter by Form, Its grayed out and can not filter it. I dug through all my resources andyoutube and found a demo on how to link un unbound field to a database. Uponviewing it, it appeared I did it correctly so I figured it may be a setting somewhere in my file. To be sure, I did a new simple version of my database asI described above. When it came to assigning a control source to the unbounded city field to database, I mimic the video and I still got the “#Name?” so its not my settings. What in the world did I do wrong?

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,771
    Field must be included in form RecordSource. Why are you including table name in the ControlSource?
    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
    sparkyinak is offline Novice
    Windows 10 Access 2016
    Join Date
    Mar 2019
    Posts
    22
    The city field (MeCityField) was included. The database is in there, when I was learning, it was recommended but not always required. In some cases it is (don’t remember why) but I made it a habit just in case. I removed it and it works. Thanx

  4. #4
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,771
    The table name would be needed if there were multiple tables in the SQL statement and there were multiple fields with the same name.
    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: 5
    Last Post: 01-21-2018, 04:06 AM
  2. Replies: 4
    Last Post: 09-04-2017, 01:41 PM
  3. assigning the inital value to an option frame control
    By markjkubicki in forum Programming
    Replies: 6
    Last Post: 08-12-2015, 07:06 AM
  4. Replies: 5
    Last Post: 06-10-2011, 03:31 PM
  5. Assigning values to Text Boxes
    By jgelpi16 in forum Programming
    Replies: 4
    Last Post: 12-11-2010, 01:26 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