Results 1 to 3 of 3
  1. #1
    ironbutterfly is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Mar 2014
    Posts
    2

    Problem with Textbox Value

    Hi, I'm very new to access. I have a form called Items. There's a checkbox called Check97 that if checked, produces a textbox called TextboxFixedWeightAmount.
    When I am using the form in form view, it lets me enter a value into the textbox but as soon as I click out of that textbox, the contents of the textbox turns to "True" and only changes back if I click inside the box.

    This is the code:

    Private Sub Check97_Click()


    If Me.Check97 = -1 Then
    Me.TextboxFixedWeightAmount.Visible = True
    Else
    Me.TextboxFixedWeightAmount.Visible = False
    Me.TextboxFixedWeightAmount.Value = Null
    End If
    End Sub


    What do I need to change? Thanks for your help!

  2. #2
    John_G is offline VIP
    Windows XP Access 2003
    Join Date
    Oct 2011
    Location
    Ottawa, ON (area)
    Posts
    2,615
    Is the textbox bound to a table field? If so, what is the data type of the field? It sounds as if it is perhaps bound to a Yes/No table field.

    John

  3. #3
    ironbutterfly is offline Novice
    Windows 7 64bit Access 2010 64bit
    Join Date
    Mar 2014
    Posts
    2
    You're right...It was bound to True/False. I changed it to General Number and now it's perfect. Thank you.

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

Similar Threads

  1. Replies: 15
    Last Post: 10-01-2013, 09:31 PM
  2. Replies: 2
    Last Post: 04-20-2013, 03:37 AM
  3. Problem checking for Null Value of a Textbox.
    By SIGMA248 in forum Programming
    Replies: 3
    Last Post: 08-09-2010, 08:56 AM
  4. Replies: 2
    Last Post: 09-26-2009, 07:19 AM
  5. Replies: 1
    Last Post: 03-25-2009, 02:20 PM

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