Before I posted, the preview view of my post was showing that some lines were being split in two as being to long.
I thought the forum would split the lines - which would have caused a compile error if you cut and pasted and got extra line breaks.
But apparently the preview was pulling my leg - it didn't split them after all.
Re Option Explicit - I consider that a good idea for all VB code.
It makes the compiler not declare things on the fly to match what you typed (or mis-typed) - a bit more trouble at compile time, but a lot less debugging at run time.
Example:
Avar = 2
AAVar = 3
this will result in two variables being created, both of type variant, one with the value of 2 the other 3.
while this example
Option Explicit
Dim AVar as Integer
Avar = 2
AAVar = 3
will result in a compile time error because AAvar was not declared and the Option Explicit makes the use of a non-declared variable an error.
Dave
P.S. Dave what did you mean by ( you will have to take out the extra CRLFs inserted by the board width limitation when this was pasted)
Also the option explicit you added at the top of the code caused the same syntax error I removed and it was fine.