![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
QT
qq_44719402
这个作者很懒,什么都没留下…
展开
-
QT网络通信TCP服务端
mianwindow.cpp #include "mainwindow.h" #include "ui_mainwindow.h" MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent), ui(new Ui::MainWindow) { ui->setupUi(this); ui->port->setText("8899"); setWindowTitle("服务器");原创 2021-07-18 19:38:28 · 160 阅读 · 1 评论 -
QT网络通信TCP客户端
QT中基于TCP套接字的网络通信需要用到两个类 QTcpServer:服务器类,用于监听客户端连接和客户端建立连接 QTcpSocket:通信套接字类,客户端和服务端都需要使用* 这两个类都属于网络通信的network 需要在工程路径下添加network QT += core gui network 服务器 mainwindow.cpp #include "mainwindow.h" #include "ui_mainwindow.h" MainWindow::MainWindow(QWi原创 2021-07-18 19:33:22 · 210 阅读 · 0 评论