For some reason the following code, which appears correct to my newbie brain, does not work. The mouseup handler belongs to a locked text field with list behavior. There is a connection to the SQLite database that has the table "cleDetails" and the variable tSubject is correctly populated with the text of the selected line, but, when the script runs, tInfo returns empty. However, for example, if I replace the tSubject variable in the 5th line with "'briefs',"
Code: Select all
put "SELECT * FROM cleDetails WHERE subject = 'briefs'" into tQuery
Code: Select all
global gCLE_DatabaseID
on mouseup
set the itemdel to tab
put the selectedtext of me into tSubject
put "SELECT * FROM cleDetails WHERE subject = '"&tSubject&"'" into tQuery
put revDataFromQuery(tab,cr,gCLE_DatabaseID,tQuery) into tInfo
set the dgText of grp "dgCLEindex" to tInfo
end mouseup
Monty May