@全体成员:提供据体图布局和源代码供大家参考,如有不理解的地方可以下载压缩包体验。
个人原创,仅供参考。
压缩包地址:https://download.csdn.net/download/ganyonjie/11431098 欢迎下载
具体布局如下:
源代码如下:
using System;
using System.IO;
using System.Windows.Forms;
namespace Game
{
public partial class SignIn : Form
{
public SignIn()
{
InitializeComponent();
}
//框架加载
private void Form1_Load(object sender, EventArgs e)
{
//读取存储的帐号信息
FileStream fileStream=null;
try
{
fileStream = new FileStream("./Login.data", FileMode.Open);
}
catch {
fileStream = new FileStream("./Login.data", FileMode.Create);
fileStream.Close();
fileStream = new FileStream("./Login.data", FileMode.Open);
}
StreamReader streamReader = new StreamReader(fileStream);
string str = streamReader.ReadToEnd();
if (str.Length > 5) {
string[] str1 = str.Split( '\n','\t');
textBox1.Text = s