简体   繁体   中英

Visual Basic 6 data structures

What are all the build in data structures for VB6 (Microsoft Access) ? I know there are arrays, but are there other more modern data structures?

断开连接的记录集也很有用: 使用VBA同步两个列表

The excellent book Hardcore Visual Basic by Bruce McKinney includes some code for creating linked lists, stacks, etc. as part of its introduction to object-based programming with VB6. The book is now available free online .

I don't think I understand the question. When I read it, I thought of:

  • Arrays
  • Collections
  • Types
  • Enums

and so forth. Not sure if I'd consider standalone class modules as part of the answer, as they can have any structure you want, rather than being a particular data structure. And, of course, VBA being COM-based, it can use any data structure from compatible COM objects. This may or may not require a type library (depends on the COM object's implementation).

You can also create your own (better accessibility/performance XML collections) in this way:

MS XML Collections

Also consider using hashtables:

Hash Tables

I written quite a lot of code in VB6 and for sure I used Dictionary and Collection classes a lot. But I still think that they are not enough in many cases, that's why I advise you to take a look at this library:

http://sourceforge.net/projects/vbcorlib/

that it's a port of .NET libraries to VB6.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM