Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
'Bug' with AddListItem in VisFox5
Message
From
28/09/1998 06:55:40
Steve Camsell
Windmill Associates
Bath, United Kingdom
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Other
Title:
'Bug' with AddListItem in VisFox5
Miscellaneous
Thread ID:
00141353
Message ID:
00141353
Views:
51
I just found out that there is a limit on the ItemId that you supply when you use the AddListItem method in a ListBox. The maximum acceptable value is 32767. There is no mention of this at all in the help file, it refers only to an integer, which I assumed would be -2,147,483,647 to 2,147,483,647. This is not the case. It also gives a very misleading error message, Function, arguement, value or type....

It's not likely that you would have that many items in your listbox, but if like me, you were using the ItemId to tie a row in the list box to a record Id instead of adding an extra invisible column to store the record id, you get a nasty little bug that is only triggered when you have got more than 32767 records in your table.

I think the least that MS could do is to mention this feature in the help file .
Steve Camsell
Development Consultant
Steve.Camsell@Windmill-DBM.Co.Uk
Next
Reply
Map
View

Click here to load this message in the networking platform