I tried rephrasing the code, but it was essentially doing the same thing. the variables "word" and "ans" are always equal to something. when the sub is first triggered, the first thing it does is assign the contents of a text box to "word" - the word that starts off the sentence generation sequence.

Ok, I have tracked down the poit where "word" reverts to its previous value:

For a = 1 To 10
Data1.Recordset.MoveFirst
--------- word = value a
Do - this is the point where the varaible changes.
--------- word = value b
If Data1.Recordset.EOF Then Exit Do
x = Data1.Recordset.Fields("words")
Data1.Recordset.MoveNext
If Data1.Recordset.EOF Then Exit Do
y = Data1.Recordset.Fields("words")
If x = word Then ans = ans & " " & y
Loop
resp = Split(ans, " ")
Randomize Timer
z = Int(Rnd * UBound(resp))
word = resp(z)
Label1.Caption = Label1.Caption & " " & word
Next a

there is nothing about the command do that can influence the content of a variable, is there? it survives the for loop, but the do loop reverts it.