>>loForm = Createobject("Form") >>loForm.Caption = "Dynamic Label Example" >>loForm.Visible = .T. >> >>CREATE CURSOR DynamicLabel (cDescript c(50)) >>INSERT INTO DynamicLabel (cDescript) VALUES ("Oustanding") >>INSERT INTO DynamicLabel (cDescript) VALUES ("Very Good") >>INSERT INTO DynamicLabel (cDescript) VALUES ("Good") >>INSERT INTO DynamicLabel (cDescript) VALUES ("Fair") > >Try this ><pre>loForm = Createobject("Form") >loForm.Caption = "Dynamic Label Example" >loForm.Visible = .T. > >CREATE CURSOR DynamicLabel (cDescript c(50)) >INSERT INTO DynamicLabel (cDescript) VALUES ("Oustanding") >INSERT INTO DynamicLabel (cDescript) VALUES ("Very Good") >INSERT INTO DynamicLabel (cDescript) VALUES ("Good") >INSERT INTO DynamicLabel (cDescript) VALUES ("Fair") >INSERT INTO DynamicLabel (cDescript) VALUES ("Unsatisfactory") >INSERT INTO DynamicLabel (cDescript) VALUES ("Not Applicable") > >GO TOP IN DynamicLabel >i = 1 >nTop = 10 >Scan >** Add Label Control > oLabel = "elbl"+Alltrim(Str(i)) > loForm.Newobject(m.oLabel, "Label") > With loForm.&oLabel > .Top = nTop > .Left = 10 > .Caption =Alltrim(cDescript) > .Visible = .T. > .AutoSize = .T. > ENDWITH > i = i + 1 > nTop = nTop + 20 >Endscan