Hi,
I've now tried all the ways I know of to trigger a QLineEdit GotFocus (Event/Signal). HOW???
Most tries don't throw any errors, just don't trigger...
/Henning
Outlet lineEdit As QLineEdit
Dim DoesHaveItFocus As Boolean
SetFocus(lineEdit)' setfocus to Qwidget
DoesHaveItFocus = lineEdit.focus' does have QWidget has focus
Signal on_lineEdit_editingFinished()
Print "Finished"
End Signal
Outlet lineEdit1 As QLineEdit Set TextBox ' add TextBox feature to the QLineEdit (actually TextBox is a sub class of QLineEdit)
Signal on_lineEdit1_GotFocus()
lineEdit1.setStyleSheet("background-color: rgb(255, 0, 0);")
End Signal
Signal on_lineEdit1_LostFocus()
lineEdit1.setStyleSheet("background-color: rgb(255, 255, 255);")
End Signal
Public Outlet txtTLVS_ID As QLineEdit Set TextBox
Signal on_txtTLVS_ID_GotFocus()
txtTLVS_ID.setStyleSheet("background-color: rgb(100, 255, 255)")
MsgBox("frm_Config", "txtTLVS_ID SetFocus")
End Signal
Henning wrote:Hi Bernd,
Tried the new Q7b, but OnFocus doesn't trigger...
- Code: Select all
Public Outlet txtTLVS_ID As QLineEdit Set TextBox
Signal on_txtTLVS_ID_GotFocus()
txtTLVS_ID.setStyleSheet("background-color: rgb(100, 255, 255)")
MsgBox("frm_Config", "txtTLVS_ID SetFocus")
End Signal
/Henning
Users browsing this forum: No registered users and 1 guest