form2.cs
来自「实现电网发电的风机监控等功能!利用以太网、plc等。在此我只是做了一个opc的客」· CS 代码 · 共 25 行
CS
25 行
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace opcClient
{
public partial class Form2 : Form
{
public Form2()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
string ip = this.textBox1.Text.Trim().ToString();
string strHostName = System.Net.Dns.GetHostEntry(ip).HostName.ToString();
this.label3.Text = strHostName;
}
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?