form2.cs

来自「利用c#编写的串口编程,开发工具是2005的开发工具」· CS 代码 · 共 36 行

CS
36
字号
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.Runtime.InteropServices;
using System.Collections;

namespace Demo
{
  
    public partial class Form2 : Form
    {
        public Form2()
        {
            InitializeComponent();
        }
      
        private void button1_Click(object sender, EventArgs e)
        {
            MessageBox(0,"hello", "thanks",0);
        }
        
        [DllImport("USER32.DLL")]
        private static extern int MessageBox(int s,string h,string r,int l);

        private void Form2_Load(object sender, EventArgs e)
        {

        }

       
    }
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?