This is where it is in the code in frm_BedCalib.QWidget.
- Code: Select all
Signal on_cmd_ReadEmpty_clicked(Checked As Boolean)
BS.bType = msgBedSensRead
BS.ID = B6TChannel * 256 + bs_Meas5Sec
BS.bSYSTEM = SystemPort
BS.unit = B6T_Unit
BS.port = 2
BS.ReplyTo = MyPort
BS.bdata[0] = B6TChannel
txt_CurrAct!setTextColor = "0,0,0"
txt_CurrAct!setText = sReadEmptyReal & sWait
'****************************
'* Call SendBSData()
'****************************
SendBSData()
If ReadBSData(msgBedSensRpt) Then
txt_CurrAct!SetText = sReadEmptyReal & sDone
txt_EmptyMin!SetText = 256 * BS_data[1] + BS_data[0]
txt_EmptyMax!SetText = 256 * BS_data[3] + BS_data[2]
Else
' Beep
txt_CurrAct!SetTextColor = "255,0,0"
txt_CurrAct!SetText = sReadEmptyReal & sFailed
End If
End Signal
Just tested to move the declarations of Type and BS to the same page (frm_BedCalib.QWidget), and then it works. When Type and BS are declared in Global.QObject it doesn't!?
Did some more testing and, from code in Module1.QObject the declares in Global.QObject works as expected!?
/Henning