S
Steve
I have the following problem. I have several tables in a document and I need
to work with the tables in a certain style. So I wrote a piece of code that
loops through the tables, checks te style and if it is a match creates a
variable in the variable collection of which the name is a counter for the
matches and the value is a counter for the tables. This works fine, but when
the matches exceed 10 the following occurs:
While looping through my variables by itemnumber the order is changed. I use
the following code:
For i = 1 To ActiveDocument.Variables.Count
iTmp = ActiveDocument.Variables(i).value
and now expect to see my matches from 1,2,3,....,9,10,11... and so on...
however I get: 1,10,11,12,..,2,3,4...
Am I doing something wrong?
to work with the tables in a certain style. So I wrote a piece of code that
loops through the tables, checks te style and if it is a match creates a
variable in the variable collection of which the name is a counter for the
matches and the value is a counter for the tables. This works fine, but when
the matches exceed 10 the following occurs:
While looping through my variables by itemnumber the order is changed. I use
the following code:
For i = 1 To ActiveDocument.Variables.Count
iTmp = ActiveDocument.Variables(i).value
and now expect to see my matches from 1,2,3,....,9,10,11... and so on...
however I get: 1,10,11,12,..,2,3,4...
Am I doing something wrong?