>I only included a portion of code that I am using in the program. The app actual uses macro expansion to determine which label gets the caption set. This is a housing program and each label represents a different room number and who is housed in the rooms.
Kendall, this can still be done without using macro expansion. Here is a code sample, which accomplishes absolutely nothing. :)
oLabel1 = createobject("label")
oLabel2 = createobject("label")
oLabel1.caption = "original caption"
cLabelName = "oLabel1"
oTempLabel = evaluate(cLabelName)
cNewCaption = "new caption"
oTempLabel.caption = cNewCaption
? oLabel1.caption
Steve Gibson