Hi everyone,
I am trying to connect to web server.For that i have 3 function(A,B,X).
code of A :-(for sending request)
mang= new QNetworkAccessManager();
connect(mang, SIGNAL(finished(QNetworkReply*)),this,SLOT(B(QNetworkReply* )));
QNetworkRequest request
(QUrl("http://192.168.1.95/test/default.aspx"));
mang->post(request,data);
mang= new QNetworkAccessManager();
connect(mang, SIGNAL(finished(QNetworkReply*)),this,SLOT(B(QNetworkReply* )));
QNetworkRequest request(QUrl("http://192.168.1.95/test/default.aspx"));
mang->post(request,data);
To copy to clipboard, switch view to plain text mode
code of B ;- (reply of server)
B( QNetworkReply* reply)
{
data=reply->readAll();
}
B( QNetworkReply* reply)
{
data=reply->readAll();
}
To copy to clipboard, switch view to plain text mode
X is the function where i am trying to call A.
But problem is the data which i received from server is required inside X (means i want to use that data inside X). But i received the data after X function.
Is there any way so that i can use the data in side X.
thanks.
Bookmarks