DEFINE CLASS cmbself_edit AS combobox Height = 22 Width = 100 DisabledBackColor = RGB(255,255,255) aliasname = "None" fieldname = "None" Name = "cmbself_edit" PROCEDURE GotFocus this.REQUERY && Do we have new elements ? this.value = eval(this.controlsource) && Reposition ENDPROC PROCEDURE InteractiveChange * * Self note : Restudy this code * *This.displayvalue = ; * Chrtran(This.displayvalue,"yi","IY") && Local language fix WITH this IF .selstart = 0 RETURN ENDIF cPos = .selstart IF lastkey() = 127 && Backspace IF .selstart = 1 .displayvalue = "" .selstart = 0 .sellength = 0 RETURN ENDIF cCheckValue = left(.displayvalue,.selstart-1) cPos = cPos - 1 ELSE cCheckValue = iif(cPos = 1,"",left(.displayvalue,cPos-1))+chr(lastkey()) ENDIF lExistsOne = .f. FOR ix = 1 to .listcount IF Upper(Alltrim(.list(ix))) = upper(alltrim(cCheckValue)) .displayvalue = .list(ix) lExistsOne = .t. EXIT ENDIF ENDFOR .selstart = cPos IF lExistsOne && Available item .sellength = len(.displayvalue) - cPos ELSE .sellength = 0 ENDIF ENDWITH ENDPROC PROCEDURE LostFocus *This.displayvalue = ; * Chrtran(This.displayvalue,"yi","IY") && Local language fix this.value = this.displayvalue this.displayvalue = this.value ENDPROC PROCEDURE Init WITH This .rowsourcetype = 3 IF lower(.fieldname)="none" or ; lower(.aliasname)="none" && Lookup is same as controlsource alias .fieldname = substr(.controlsource,rat(".",.controlsource)+1) .aliasname = substr(.controlsource,1,; rat(".",.controlsource)-1) ENDIF .rowsource = [SELECT DISTINCT ]+THIS.fieldname +; [ as dummy FROM ]+this.aliasname+[ where !empty(]+THIS.fieldname + ; [) union ] +; [SELECT this.displayvalue as dummy ] +; [ FROM ]+this.aliasname + ; [ union ] +; [SELECT this.value as dummy ] +; [ FROM ]+this.aliasname + ; [ INTO cursor qq order by 1 ] IF .parent.baseclass = "Column" .parent.sparse = .t. && Force sparse .t. for grids ENDIF ENDWITH ENDPROC ENDDEFINEYou can drop interactivechange. Sparse setting was always a problem so I forced it to be .t. You could implement this to rowsourcetype = Array also. Hope helps.