** END HEADER -- do not remove this line // // Generated on 12/10/2021 // parameter bModal local f f = new Grid_SpeedtipForm() if (bModal) f.mdi = false // ensure not MDI f.readModal() else f.open() endif class Grid_SpeedtipForm of FORM with (this) onOpen = class::FORM_ONOPEN scaleFontName = "Calibri" scaleFontSize = 12.0 metric = 6 // Pixels height = 400.0 left = 117.0 top = 277.0 width = 811.0 text = "" endwith this.DBASESAMPLES1 = new DATABASE(this) with (this.DBASESAMPLES1) left = 18.0 top = 352.0 width = 78.0 height = 37.0 databaseName = "DBASESAMPLES" active = true endwith this.CUSTOMERS1 = new QUERY(this) with (this.CUSTOMERS1) left = 119.0 top = 343.0 width = 63.0 height = 37.0 database = form.dbasesamples1 sql = "select * from CUSTOMERS.DBF" active = true endwith with (this.CUSTOMERS1.rowset) onNavigate = class::ROWSET_ONNAVIGATE indexName = "COMPANY" endwith this.TEXT1 = new TEXT(this) with (this.TEXT1) height = 57.0 left = 20.0 top = 7.0 width = 408.0 fontName = "Calibri" fontSize = 12.0 text = '

Miland Speedtip with Grid Column Example

Uses SAMPLES table "Customers"

' endwith this.GRID1 = new GRID(this) with (this.GRID1) fontName = "Calibri" fontSize = 12.0 headingFontName = "Calibri" headingFontSize = 12.0 dataLink = form.customers1.rowset columns["COLUMN1"] = new GRIDCOLUMN(form.GRID1) with (columns["COLUMN1"]) dataLink = form.customers1.rowset.fields["company"] editorType = 1 // EntryField width = 231.0 endwith columns["COLUMN2"] = new GRIDCOLUMN(form.GRID1) with (columns["COLUMN2"]) dataLink = form.customers1.rowset.fields["firstname"] editorType = 1 // EntryField width = 150.0 endwith columns["COLUMN3"] = new GRIDCOLUMN(form.GRID1) with (columns["COLUMN3"]) dataLink = form.customers1.rowset.fields["lastname"] editorType = 1 // EntryField width = 150.0 endwith columns["COLUMN4"] = new GRIDCOLUMN(form.GRID1) with (columns["COLUMN4"]) dataLink = form.customers1.rowset.fields["city"] editorType = 1 // EntryField width = 200.0 endwith with (columns["COLUMN1"].editorControl) fontName = "" speedTip = "Starting Text for Speedtip" endwith with (columns["COLUMN1"].headingControl) fontName = "" value = "Company" endwith with (columns["COLUMN2"].editorControl) fontName = "" endwith with (columns["COLUMN2"].headingControl) fontName = "" value = "FirstName" endwith with (columns["COLUMN3"].editorControl) fontName = "" endwith with (columns["COLUMN3"].headingControl) fontName = "" value = "LastName" endwith with (columns["COLUMN4"].editorControl) fontName = "" endwith with (columns["COLUMN4"].headingControl) fontName = "" value = "City" endwith headingHeight = 25.0 cellHeight = 25.0 height = 255.0 left = 22.0 top = 72.0 width = 759.0 endwith this.rowset = this.customers1.rowset function form_onOpen() // force the rowset to navigate so the speedTip // updates: form.rowset.first() return function rowset_onNavigate(type, nRows) // need a form reference, because rowset // doesn't understand what "form" means. // this = rowset // parent = query // parent = form oForm = this.parent.parent oForm.grid1.columns["COLUMN1"].editorControl.speedTip := ; this.fields["Company"].value.rightTrim() return endclass