Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2003
    Posts
    41

    Unanswered: Clearing out Textbox within a Sub-Form on Main Form

    Good day,

    I have a command button on subform A and I want to clear out a textbox on Form B. I have tried the code below but Access returns an error explaining that it can't find the txtsearchcasenum texbox.

    Forms!FormB.Form!txtsearchcasenum.SetFocus
    Forms!FormB.Form!txtsearchcasenum.Text = ""

    I am using Access 2000
    Any Ideas?

    Thanks

  2. #2
    Join Date
    Mar 2003
    Location
    The Bottom of The Barrel
    Posts
    6,102
    Provided Answers: 1
    the .form is unnecessary

    try:
    Forms!FormB!txtsearchcasenum.SetFocus
    Forms!FormB!txtsearchcasenum.Text = ""
    oh yeah... documentation... I have heard of that.

    *** What Do You Want In The MS Access Forum? ***

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •