DEFINE CLASS TestForm AS form ADD OBJECT cbostates AS cmbobox WITH ; ColumnCount = 1, ; ColumnWidths = "120", ; RowSourceType = 3, ; RowSource = "select distinct state from r6snc order by State into cursor crsStates", ; Height = 24, ; ColumnLines = .F., ; Left = 51, ; Top = 16, ; Width = 74, ; Name = "cboStates" ADD OBJECT cbocities AS cmbobox WITH ; ColumnCount = 1, ; ColumnWidths = "200", ; Height = 24, ; ColumnLines = .F., ; Left = 223, ; Top = 17, ; Width = 262, ; Name = "cboCities" PROCEDURE cbostates.intactchange with This.Parent.cboCities .cState = This.DisplayValue .Requery() endwith ENDPROC PROCEDURE cbocities.Init DoDefault() This.AddProperty('cState', '~~') This.RowSource = 'select distinct city from r6snc where State = ?ThisForm.cboCities.cState order by City into cursor crsCities' This.RowSourceType = 3 ENDPROC ENDDEFINE