type access

A

alvis

i have a type (see partial below)
after i create a varable dim pfile as tloanset. is there a way that i can
dynamicly load the new variable i want to do something like this

for i = 0 to ubound(pfile)
pfile(i) = "xyx"
next i
i know that the code above does not work but i want a way to load the type
dynamicly is this possible?


Type tLoanSet
LoanNumber As String
TeamName As String
UserTeamName As String
IntRate As Double
startrate As Double
loanterm As Integer
AmortTerm As Integer
End Type
 
M

M.L. Sco Scofield

A type is neither a collect nor an array, so all of he techniques to
remunerate elements with no work.

Besides, it kind of defeats the purpose of using a type, to have named
elements.

If you want to work with the variable as an array, why not just use an
array?

If you really want something that you can use like a type and an array, you
might look into creating your own class and using either the Collection
object or the Dictionary object.

Start searching help and take a look at
http://support.microsoft.com/kb/198465/EN-US/ and
http://support.microsoft.com/kb/187234/EN-US/.

Good luck.

Sco

M.L. "Sco" Scofield, Microsoft Access MVP, MCSD, MCP, MSS, A+
Denver Area Access Users Group Communications Director www.DAAUG.org
MS Colorado Events Administrator www.MSColoradoEvents.com
Useful Metric Conversion #18 of 19: 8 nickels = 2 paradigms (My personal
favorite)
Miscellaneous Access and VB "stuff" at www.ScoBiz.com
 
Top