Results 1 to 4 of 4
  1. #1
    samsquared is offline Novice
    Windows 10 Access 2010 64bit
    Join Date
    May 2021
    Location
    St. Augustine, FL
    Posts
    20

    Calculated unbound control in form returning wrong value (really wrong)

    I have a simple form that has room dimensions (from the Room_Dimensions table) for rental houses with these items:



    • Property_ID
    • Room_Type_ID
    • Length
    • Width
    • Height



    Length, Width, and Height are all numeric, precision 6, and 2 decimal places. I added a calculated field for the floor area as follows:


    =[Width]*[Length]


    Sample values I put in were Width = 10, Length = 15, and Height = 9. The resulting calculated area was 177645!! I then modified that control to "=[Length]*1" and added a second calculated control to be "=[Width]*1" to try to see what was going on (see attached photos).


    Calculations using Height and Length are fine but not Width. I'm sure it's something simple but I really have no idea what is going on.

    Click image for larger version. 

Name:	Room Dim 2.JPG 
Views:	12 
Size:	17.0 KB 
ID:	51381Click image for larger version. 

Name:	Room Dim 1.JPG 
Views:	12 
Size:	83.6 KB 
ID:	51382

  2. #2
    moke123's Avatar
    moke123 is online now Me.Dirty=True
    Windows 11 Office 365
    Join Date
    Oct 2012
    Location
    Ma.
    Posts
    1,654
    Width and height are reserved words and should not be used as field or object names.
    If this helped, please click the star * at the bottom left and add to my reputation- Thanks

  3. #3
    samsquared is offline Novice
    Windows 10 Access 2010 64bit
    Join Date
    May 2021
    Location
    St. Augustine, FL
    Posts
    20
    That was it - thanks for the quick reply! I don't use Access all the time so it didn't occur to me that they could be reserved words.

  4. #4
    moke123's Avatar
    moke123 is online now Me.Dirty=True
    Windows 11 Office 365
    Join Date
    Oct 2012
    Location
    Ma.
    Posts
    1,654
    You're welcome.

    here's one list http://allenbrowne.com/AppIssueBadWord.html
    If this helped, please click the star * at the bottom left and add to my reputation- Thanks

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

Similar Threads

  1. Iff statement returning the wrong value
    By rmoore in forum Access
    Replies: 6
    Last Post: 02-19-2020, 04:11 AM
  2. Query sum returning wrong value
    By MrBologna in forum Queries
    Replies: 9
    Last Post: 10-29-2018, 02:48 PM
  3. Forms - returning wrong value
    By Sheba in forum Forms
    Replies: 1
    Last Post: 11-12-2014, 02:02 PM
  4. Returning wrong items
    By cbende2 in forum Access
    Replies: 5
    Last Post: 08-01-2014, 07:43 AM
  5. DMax returning wrong value
    By nedbenj in forum Access
    Replies: 7
    Last Post: 10-24-2007, 10:30 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