winform
杰宝多多
这个作者很懒,什么都没留下…
展开
-
winform监听关闭按钮并弹出是否关闭的提示框
private void Client_FormClosing(object sender, FormClosingEventArgs e) { DialogResult TS = MessageBox.Show("退出?", "提示", MessageBoxButtons.YesNo, MessageBoxIcon.Question); if (TS == DialogResult.Yes) ...原创 2020-06-10 10:45:17 · 467 阅读 · 0 评论 -
winform使用GET、POST方法调用接口
public static string HttpPost(string url, string body) { //ServicePointManager.ServerCertificateValidationCallback = new RemoteCertificateValidationCallback(CheckValidationResult); Encoding encoding = Encoding.UTF8; ...原创 2020-06-10 10:44:18 · 1679 阅读 · 1 评论 -
winform内嵌Chrome浏览器
private void InitChrome() { CefSettings setting = new CefSettings(); Cef.EnableHighDPISupport(); Cef.Initialize(setting); }原创 2020-06-10 10:41:54 · 1617 阅读 · 0 评论 -
winform获取本机mac地址
private string GetMacAddress() { System.Net.IPHostEntry myEntry = System.Net.Dns.GetHostEntry(System.Net.Dns.GetHostName()); //string ipAddress = myEntry.AddressList[0].ToString(); List<string> macList = .原创 2020-06-10 10:40:25 · 911 阅读 · 1 评论 -
Winform生成Json文件并保存到指定文件夹
一个前端写winform真的我太难了这是一个简单的页面,可以将数据保存到json文件里面并存放到指定位置,相关的包需要自己导入using Newtonsoft.Json;using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.IO;using System.Linq;using Syste原创 2020-06-10 10:39:20 · 1741 阅读 · 0 评论