FIX: "Data Type Mismatch" Error Message Using ASORT()Last reviewed: October 14, 1997Article ID: Q88137 |
2.00 2.50 2.50a | 2.50 2.50a
MS-DOS | WINDOWSkbenv kbprg kbfixlist kbbuglist kberrmsg The information in this article applies to:
SYMPTOMSThe FoxPro ASORT() function sorts an array into ascending or descending order. When an application uses the ASORT() function, all the elements in the array must have the same data type (character, numeric, date, or logical). Otherwise, the ASORT() function causes a "data type mismatch" error. NOTE: This bug does not occur in FoxPro for Macintosh.
WORKAROUNDUse the following code to sort the array by the character field:
USE SYS(2004)+"\Tutorial\INVOICES" SELECT cno,idate,ino from invoices INTO ARRAY ainv =ASORT(ainv,aelement(ainv,1,1)) DISPLAY MEMORY STATUSMicrosoft has confirmed this to be a problem in the Microsoft products listed at the beginning of this article. This problem was corrected in FoxPro version 2.5b for Windows.
REFERENCESMicrosoft FoxPro "Commands & Functions" manual, chapter 3 "Commands and Functions, ASORT()"
|
Additional reference words: FoxDos FoxWin 2.00 2.50 2.50a buglist2.00
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |