array of structures question

  • Thread starter Thread starter aprivate
  • Start date Start date
A

aprivate

Hi
I need help with a code snippet for the following
problem.

1. I have 2 elements , one is a datetime element and another is an integer
2. I would like to store this in a array so that for each index of the array
I can refer to the integer value or the datetime value.

I think I need some kind of structure that a 1 dimensional array can point
to
and this structure that contains the 2 data types

How can I declare this and access this structure?


Allan
 
aprivate said:
1. I have 2 elements , one is a datetime element and another is an integer
2. I would like to store this in a array so that for each index of the
array
I can refer to the integer value or the datetime value.

I think I need some kind of structure that a 1 dimensional array can point
to
and this structure that contains the 2 data types

How can I declare this and access this structure?

\\\
Public Structure Item
Public StartDate As Date
Public Number As Integer
End Structure
..
..
..
Dim Items(10) As Item
///
 
Hi
Thanks
This is what I need..!

Regds
Allan
Herfried K. Wagner said:
\\\
Public Structure Item
Public StartDate As Date
Public Number As Integer
End Structure
.
.
.
Dim Items(10) As Item
///
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top