ACC97: Buddy Properties for UpDown Control Don't Work in Access

Last reviewed: November 12, 1997
Article ID: Q161402
The information in this article applies to:
  • Microsoft Access 97

SYMPTOMS

Novice: Requires knowledge of the user interface on single-user computers.

When you use the Microsoft UpDown Control, version 5.0, in Microsoft Access 97, you cannot use any of the Buddy properties of the control. Depending on what you are trying to do, you may receive one or more of the following error messages:

   Microsoft Access can't find the field '<name>' referred to in your
   expression.

   BuddyControl must be a separate control within the same container.

   BuddyControl property must be set first.

   Invalid property value.

CAUSE

The Buddy properties of the UpDown control are not supported by Microsoft Access 97. The Buddy properties contain specific functionality that is supported in Microsoft Visual Basic. In Microsoft Word 97, Microsoft Excel 97, and Microsoft PowerPoint 97, this functionality is also supported in an UpDown control on a UserForm that you have created in Visual Basic for Applications.

RESOLUTION

Do not use any of the Buddy properties of the UpDown control in Microsoft Access 97.

MORE INFORMATION

The Microsoft UpDown Control, version 5.0 is included with Microsoft Office 97 Developer Edition as a replacement for the SpinButton Control from earlier versions.

You can use the UpDown control in Microsoft Access 97 with the exception of the following Buddy properties:

   BuddyControl
   SyncBuddy
   AutoBuddy
   BuddyProperty

In Microsoft Visual Basic 5.0, when you place the UpDown control on a form, you can set the BuddyControl property to a text box that contains a numeric value. Then, without writing any code, you are able to run the form and click the UpDown control to increment or decrement the numeric value in the text box. This feature does not work in Microsoft Access 97.

Steps to Reproduce Behavior

  1. Open the sample database Northwind.mdb.

  2. Create a new form not based on any table or query in Design view.

  3. On the Insert menu, click ActiveX Control.

  4. In the Insert ActiveX Control dialog box, select Microsoft UpDown Control, version 5.0, and then click OK.

  5. Add a text box control to the form, and set its Name property to Text0.

  6. Double-click the UpDown control to invoke the UpDown Properties dialog box.

  7. Click the Buddy tab, and then begin to type Text0 in the Buddy Control box. Note that as soon as you type the letter T, you receive the following error message:

          Microsoft Access can't find the field 'T' referred to in your
          expression.
    

REFERENCES

For more information about using the UpDown control, search the Help Index for "UpDown control."


Additional query words: Spinner OCX ActiveX OLE Control ADT Developer's
Toolkit
Keywords : kberrmsg kbusage
Version : 97
Platform : WINDOWS
Hardware : x86
Issue type : kbprb
Solution Type : Info_Provided


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: November 12, 1997
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.