Nightmare in API 2.0

Trying to transition my primary project from RecordSet to RowSet going from API 1.0 to 2.0 was a big in itself, but I got through it. Now I need to change one class from a ListBox to DeskTopListBox…


I can understand the need to change some of the event and method names due to changes like one to zero base referencing. I can even understand name convention changing for consistency, but why did you decide to deprecate the old events and methods completely? :frowning:

there are some menüs in the ide to move to api2.
for some other issues maybe use your own sub class or extends.

Are-you using 2022r3 ?

Yes, 22R3. I was getting away with not needing to change my classes up to now but an EventDefinition is no longer firing reliably which I figured may be related to me using the ListBox. It’s hard to know what the best approach to take is now :frowning:

Haven’t seen that before. Please try to isolate the problem.

You can’t partialy deprecate something.

You shouldn’t try to do too much at once. I suggest you have the API1 class and the equivalent API2 class with a slightly different name, in your app at the same time. Then you can move each instance over, one by one. When there are no more instances left of the old class, delete it and do a global name change for the API2 class.

See also:

Thanks Beatrix - Ya, I’ve decided to at least work around it - Worrying though.

Have-you tried that with Xojo 2022r3 ?
If no, try, then feedback what you found.

I don’t have any API1 classes to try it on.

Thanks Tim. It’s good advice and I’ll probably take that route. I toyed with the idea of changing to Jim Kay’s excellent DataView for the added features, but with the new grid control on the way, changing is a less attractive idea.