登录
首页 » C# » Socket通信(含服务器端以及客户端源码)

Socket通信(含服务器端以及客户端源码)

于 2018-12-19 发布
0 325
下载积分: 1 下载次数: 0

代码说明:

实现服务的和客户端连接通信,客户端可发送接收服务端信息

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • C# 套打Demo
    套打Demo 【核心代码】using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Text;using System.Windows.Forms;using System.Drawing.Printing;namespace Print_Demo{ public partial class Form1 : Form { public PrintDocument printDt = new PrintDocument(); //打印文档对象 Font printFont; //打印使用的字体 public Form1() { InitializeComponent(); } void printDt_PrintPage(object sender, PrintPageEventArgs e) { float pointX = 10; float pointY = 10; e.Graphics.DrawString("打印内容", new Font("宋体", 16F), Brushes.Black, pointX 60, pointY); e.Graphics.DrawLine(new Pen(Color.Black), pointX, pointY 26,pointX 300,pointY 26); e.Graphics.DrawString("打印内容", printFont, Brushes.Black, pointX, pointY 35); e.Graphics.DrawLine(new Pen(Color.Black), pointX, pointY 56, pointX 300, pointY 56); e.Graphics.DrawString("打印内容", printFont, Brushes.Black, pointX, pointY 65); e.Graphics.DrawLine(new Pen(Color.Black), pointX, pointY 86, pointX 300, pointY 86); e.Graphics.DrawString("打印内容", printFont, Brushes.Black, pointX, pointY 95); e.Graphics.DrawLine(new Pen(Color.Black), pointX, pointY 116, pointX 300, pointY 116); e.Graphics.DrawString("打印内容", printFont, Brushes.Black, pointX, pointY 125); e.Graphics.DrawLine(new Pen(Color.Black), pointX, pointY 146, pointX 300, pointY 146); e.Graphics.DrawString("打印内容", printFont, Brushes.Black, pointX, pointY 155); e.Graphics.DrawLine(new Pen(Color.Black), pointX, pointY 176, pointX 300, pointY 176); e.Graphics.DrawString("打印内容", printFont, Brushes.Black, pointX, pointY 185); e.Graphics.DrawLine(new Pen(Color.Black), pointX, pointY 206, pointX 300, pointY 206); e.Graphics.DrawString("检测结果", printFont, Brushes.Black, pointX, pointY 233); e.Graphics.DrawString("通过", new Font("宋体",22F,FontStyle.Bold), Brushes.Black, pointX 90, pointY 225); e.Graphics.DrawLine(new Pen(Color.Black), pointX, pointY 265, pointX 300, pointY 265); e.Graphics.DrawString("单位名称", printFont, Brushes.Black, pointX, pointY 275); } private void Form1_Load(object sender, EventArgs e) { printDt.PrintPage = new PrintPageEventHandler(printDt_PrintPage); printFont = new Font("宋体", 12F); } private void btnPrint_Click(object sender, EventArgs e) { //PrintDialog printDlg = new PrintDialog(); //printDlg.Document = printDt; //printDlg.AllowPrintToFile = true; //printDlg.AllowCurrentPage = true; //printDlg.AllowSelection = true; //printDlg.ShowDialog(); //printDlg.ShowDialog(); printDt.Print(); } private void btnLook_Click(object sender, EventArgs e) { PrintPreviewDialog printPreview = new PrintPreviewDialog(); printPreview.PrintPreviewControl.Document = printDt; printPreview.ShowDialog(this); } }}
    2021-05-06下载
    积分:1
  • 用 C#制作 PDF 文件全攻略(PDF)
    第一部分 iText的简单应用  第二部分 其他文档格式第三部分 iText的高级应用
    2014-04-14下载
    积分:1
  • 获取CPU ID 和 HD ID
    【实例简介】获取CPU ID 和 HD ID 获取CPU和硬盘ID,适合新手,简单明了
    2022-01-17 00:31:27下载
    积分:1
  • 联系人管理实例源码下载
    联系人管理实例源码下载
    2014-07-29下载
    积分:1
  • html5 超炫进度条实例源码(粒子效果)
    html5 超炫进度条实例源码(粒子效果)
    2014-08-04下载
    积分:1
  • C# WinForm 于Socket的聊天室
    基于Socket的聊天室 实现功能: 1、服务器和客户端的创建 2、用户状态显示、系统消息提示 3、公聊、私聊 4、界面字体颜色设置
    2021-05-07下载
    积分:1
  • wpf开发教程 下载(259页)
    wpf开发教程 下载(259页)
    2014-06-17下载
    积分:1
  • CrystalDiskMark硬盘测试工具 源码
    CrystalDiskMark硬盘测试工具 源码
    2019-08-17下载
    积分:1
  • 【0013】S7-200与变频器USS通讯控制生活消防两用水泵
    【实例简介】
    2021-08-08 00:31:03下载
    积分:1
  • C#音乐播放器(支持歌词)
    C#音乐播放器(支持歌词)
    2020-05-06下载
    积分:1
  • 696516资源总数
  • 106914会员总数
  • 0今日下载