Hello sir thanks for your time and help, This is the function i am calling every 2 seconds. The data is present in the QString just before the data insertion but its not saved into the data base.
void datareceiver::aligndata()
{
for(int k=0; k<newdat.size(); k+=4)
{
nudata.append(newdat.mid(k, 4));
}
for(int p = 0; p < nudata.count();p++)
{
lstdata = nudata.at(p);
}
if(lstdata!=0)
{
textBrowser_2->append(lstdata); \\ The data is displayed in the text browser but not in the data base.
m_query.exec(sq);
}
}
void datareceiver::aligndata()
{
for(int k=0; k<newdat.size(); k+=4)
{
nudata.append(newdat.mid(k, 4));
}
for(int p = 0; p < nudata.count();p++)
{
lstdata = nudata.at(p);
}
if(lstdata!=0)
{
textBrowser_2->append(lstdata); \\ The data is displayed in the text browser but not in the data base.
QString sq = QString("insert into thdata values(%1);").arg(lstdata);
m_query.exec(sq);
}
}
To copy to clipboard, switch view to plain text mode
the data is present in the String but its not updated into the db.
what do you think can be going wrong.
thank you
Bookmarks