Data manipulation Question

  • Thread starter Thread starter pmclinn
  • Start date Start date
P

pmclinn

I'm creating a dll to handle a 'find and replace' function in serveral
of my programs. (Runs using Word Documents)

I want to pass my dll an array list that has the following pseudo
structure:

String(i,2) 'where i increments +1
string(i,0) will = the find value
and string(i,1) will = the replacement string

or something like:

Structure FindReplace
Dim FindItem As String
Dim ReplaceWith As String
End Structure

MyArraylist.add(string())

Is there a way to force an arraylist to have a certain structure/class?
What is the best way to collect this information.


I want it to be obvious that the data should always be in this format,
so that when I refrence this class in 3 months, it will be intuitive to
how this was configured without looking at the source code.

-Peter
 
why don't you pass your dll an array of FindReplace structures?

Alejandro Lapeyre
 
That's what he wanted to do. His question was how to make that array
strongly typed.

Chris
 
an Array of MyStructure is strongly typed
an ArrayList is not

Alejandro Lapeyre
 
No, you are correct, my bad.

Chris

alejandro lapeyre said:
an Array of MyStructure is strongly typed
an ArrayList is not

Alejandro Lapeyre
 
Back
Top