QMetaObject::connectSlotsByName: No matching signal
-
Hi ,
I m using Qt5.11.1My application is running fine for all the time and no error/warnings.But when I configure the Gateway and Local IP for ethernet from Rpi3 to my Device.I m having the below issue and my app in not opening at all.
Please suggest on the same.QMetaObject::connectSlotsByName: No matching signal for on_pushButton_2_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_counterDataStreaming_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_adcDataStreaming_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_stopDataStreaming_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_checkBox_clicked(bool)
QMetaObject::connectSlotsByName: No matching signal for on_checkBox_2_clicked(bool)
QMetaObject::connectSlotsByName: No matching signal for on_pushButton_5_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_pushButton_6_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_pushButton_7_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_Chekck_Connection_Timer()
CUSTOMER_MODE
QObject::connect: No such signal QUdpSocket::stateChanged(QAbstractSocket::SocketError)
QObject::connect: (receiver name: 'MainWindow') -
Hi ,
I m using Qt5.11.1My application is running fine for all the time and no error/warnings.But when I configure the Gateway and Local IP for ethernet from Rpi3 to my Device.I m having the below issue and my app in not opening at all.
Please suggest on the same.QMetaObject::connectSlotsByName: No matching signal for on_pushButton_2_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_counterDataStreaming_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_adcDataStreaming_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_stopDataStreaming_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_checkBox_clicked(bool)
QMetaObject::connectSlotsByName: No matching signal for on_checkBox_2_clicked(bool)
QMetaObject::connectSlotsByName: No matching signal for on_pushButton_5_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_pushButton_6_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_pushButton_7_clicked()
QMetaObject::connectSlotsByName: No matching signal for on_Chekck_Connection_Timer()
CUSTOMER_MODE
QObject::connect: No such signal QUdpSocket::stateChanged(QAbstractSocket::SocketError)
QObject::connect: (receiver name: 'MainWindow') -
void MainWindow::on_counterDataStreaming_clicked()
{
QByteArray byArrSendPkt;
CProtocol objProtocol;
QHostAddress hostIp;
hostIp.setAddress("13.13.13.13");//10.0.0.178
objProtocol.mPktCmdWrite(STREAMINGSTRAT, STREAMINGREG, STREAMINGCOUNTER, byArrSendPkt);
m_SockUdp_ReagWrt.writeDatagram(byArrSendPkt,hostIp,60012);
}void MainWindow::on_adcDataStreaming_clicked()
{
QByteArray byArrSendPkt;
CProtocol objProtocol;
QHostAddress hostIp;
hostIp.setAddress("13.13.13.13");//10.0.0.178
objProtocol.mPktCmdWrite(STREAMINGSTRAT, STREAMINGREG, STREAMINGADCDATA, byArrSendPkt);
m_SockUdp_ReagWrt.writeDatagram(byArrSendPkt,hostIp,60012);
}void MainWindow::on_stopDataStreaming_clicked()
{
QByteArray byArrSendPkt;
CProtocol objProtocol;
QHostAddress hostIp;
hostIp.setAddress("13.13.13.13");//10.0.0.178
objProtocol.mPktCmdWrite(STREAMINGSTOP, STREAMINGREG, STREAMINGSTOPDATA, byArrSendPkt);
m_SockUdp_ReagWrt.writeDatagram(byArrSendPkt,hostIp,60012);
}
connect(checK_ConnectionStatus,SIGNAL(timeout()),this,SLOT(on_Chekck_Connection_Timer()));connect(&m_sockUdp, SIGNAL(stateChanged(QAbstractSocket::SocketError)),this,SLOT(mSltOnTCPStateChanged(QAbstractSocket::SocketState)));
-
void MainWindow::on_counterDataStreaming_clicked()
{
QByteArray byArrSendPkt;
CProtocol objProtocol;
QHostAddress hostIp;
hostIp.setAddress("13.13.13.13");//10.0.0.178
objProtocol.mPktCmdWrite(STREAMINGSTRAT, STREAMINGREG, STREAMINGCOUNTER, byArrSendPkt);
m_SockUdp_ReagWrt.writeDatagram(byArrSendPkt,hostIp,60012);
}void MainWindow::on_adcDataStreaming_clicked()
{
QByteArray byArrSendPkt;
CProtocol objProtocol;
QHostAddress hostIp;
hostIp.setAddress("13.13.13.13");//10.0.0.178
objProtocol.mPktCmdWrite(STREAMINGSTRAT, STREAMINGREG, STREAMINGADCDATA, byArrSendPkt);
m_SockUdp_ReagWrt.writeDatagram(byArrSendPkt,hostIp,60012);
}void MainWindow::on_stopDataStreaming_clicked()
{
QByteArray byArrSendPkt;
CProtocol objProtocol;
QHostAddress hostIp;
hostIp.setAddress("13.13.13.13");//10.0.0.178
objProtocol.mPktCmdWrite(STREAMINGSTOP, STREAMINGREG, STREAMINGSTOPDATA, byArrSendPkt);
m_SockUdp_ReagWrt.writeDatagram(byArrSendPkt,hostIp,60012);
}
connect(checK_ConnectionStatus,SIGNAL(timeout()),this,SLOT(on_Chekck_Connection_Timer()));connect(&m_sockUdp, SIGNAL(stateChanged(QAbstractSocket::SocketError)),this,SLOT(mSltOnTCPStateChanged(QAbstractSocket::SocketState)));
@shivaVMC Please take a look at the documentation: http://doc.qt.io/qt-5/qabstractsocket.html#stateChanged
-
Hi,
I couldn't find anything that helps me to fix my bug,can you please suggest me on this@shivaVMC stateChanged signal has a different parameter than the one your using:
connect(&m_sockUdp, SIGNAL(stateChanged(QAbstractSocket::SocketError)),this,SLOT(mSltOnTCPStateChanged(QAbstractSocket::SocketState)));
Look once more.
-
-
@shivaVMC You don't need to register anything as you're not using queued connection. Simply use the correct parameter type for the signal...
@jsulm said in QMetaObject::connectSlotsByName: No matching signal:
@shivaVMC You don't need to register anything as you're not using queued connection. Simply use the correct parameter type for the signal...
Oh, missed that...
-
I m not able to fix it....I need your support
connect(&m_sockUdp,SIGNAL(readyRead()),this,SLOT(mSltOnTCPDataReceivedFromClient()));
connect(ui->btnConnect,SIGNAL(clicked()),this,SLOT(mSltOnBtnConnectClick()));connect(&m_sockUdp, SIGNAL(stateChanged(QAbstractSocket::SocketError)),this,SLOT(mSltOnTCPStateChanged(QAbstractSocket::SocketState)));
Above 3 statement of code are contiguous in my function,at 3rd connect statement I m faccing issue ...
In SIGNAL stateChanged what will be the correct parameter? -
I m not able to fix it....I need your support
connect(&m_sockUdp,SIGNAL(readyRead()),this,SLOT(mSltOnTCPDataReceivedFromClient()));
connect(ui->btnConnect,SIGNAL(clicked()),this,SLOT(mSltOnBtnConnectClick()));connect(&m_sockUdp, SIGNAL(stateChanged(QAbstractSocket::SocketError)),this,SLOT(mSltOnTCPStateChanged(QAbstractSocket::SocketState)));
Above 3 statement of code are contiguous in my function,at 3rd connect statement I m faccing issue ...
In SIGNAL stateChanged what will be the correct parameter?@shivaVMC
"In SIGNAL stateChanged what will be the correct parameter?" - why don't you read the documentation? I even posted a link to it here.connect(&m_sockUdp, SIGNAL(stateChanged(QAbstractSocket::SocketState)),this,SLOT(mSltOnTCPStateChanged(QAbstractSocket::SocketState)));
-
@shivaVMC
"In SIGNAL stateChanged what will be the correct parameter?" - why don't you read the documentation? I even posted a link to it here.connect(&m_sockUdp, SIGNAL(stateChanged(QAbstractSocket::SocketState)),this,SLOT(mSltOnTCPStateChanged(QAbstractSocket::SocketState)));
-
Hi,
I m not able to enter into "if" condition(first if condition),can you please suggest on the below code where I m going wrong.bjProtocol.mPktRegRead(a_nAddress,byArrSendPkt); //Its entering into this mPktRegRead funtion and return value is fine qDebug()<<"Send Pkt count ===="<<byArrSendPkt.count(); //this debug is also okay
can you please help on this below lines where I m doing wrong
m_SockUdp_ReagWrt.writeDatagram(byArrSendPkt,hostIp,60014); if(m_sockUdpRegRd.waitForReadyRead(SOCKET_CMND_TIMEOUT_IN_MSEC)){ if( m_sockUdpRegRd.hasPendingDatagrams() ) { //statements } //statemnets }
-
Hi,
I m not able to enter into "if" condition(first if condition),can you please suggest on the below code where I m going wrong.bjProtocol.mPktRegRead(a_nAddress,byArrSendPkt); //Its entering into this mPktRegRead funtion and return value is fine qDebug()<<"Send Pkt count ===="<<byArrSendPkt.count(); //this debug is also okay
can you please help on this below lines where I m doing wrong
m_SockUdp_ReagWrt.writeDatagram(byArrSendPkt,hostIp,60014); if(m_sockUdpRegRd.waitForReadyRead(SOCKET_CMND_TIMEOUT_IN_MSEC)){ if( m_sockUdpRegRd.hasPendingDatagrams() ) { //statements } //statemnets }
@shivaVMC said in QMetaObject::connectSlotsByName: No matching signal:
if( m_sockUdpRegRd.hasPendingDatagrams()
Why do you need this if? After waitForReadyRead() you know that there is something to read.
-
Hi,
I m not able to enter into "if" condition(first if condition),can you please suggest on the below code where I m going wrong.bjProtocol.mPktRegRead(a_nAddress,byArrSendPkt); //Its entering into this mPktRegRead funtion and return value is fine qDebug()<<"Send Pkt count ===="<<byArrSendPkt.count(); //this debug is also okay
can you please help on this below lines where I m doing wrong
m_SockUdp_ReagWrt.writeDatagram(byArrSendPkt,hostIp,60014); if(m_sockUdpRegRd.waitForReadyRead(SOCKET_CMND_TIMEOUT_IN_MSEC)){ if( m_sockUdpRegRd.hasPendingDatagrams() ) { //statements } //statemnets }