⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 recvivemessagebox.cs

📁 功能比较强大的短信收发系统功能比较强大。
💻 CS
字号:
using System;
using System.IO;
using System.Collections;
namespace ShInfo
{
	/// <summary>
	/// Recvivemessagebox 的摘要说明。
	/// </summary>
	public class Recvivemessagebox
	{
		public Recvivemessagebox()
		{
		}
		//未读信息读写流;
		public void Wsendinfo(ShortMessage ff)
		{
			FileStream fs2=new FileStream("未读信息.txt",FileMode.Append);
			StreamWriter sw2=new StreamWriter(fs2);
			sw2.WriteLine("收信人:"+ff.Jnum);
			sw2.WriteLine("短信内容:"+ff.Minfo);
			sw2.WriteLine("发送人:"+ff.Fnum);
			sw2.WriteLine("发送时间:"+ff.Datetime);
			sw2.WriteLine("—————————————");
			sw2.Close();
			fs2.Close();
		}
		public ArrayList Wreadinfo()
		{
			FileStream fs3=new FileStream("未读信息.txt",FileMode.Open,FileAccess.Read);
			StreamReader sw3=new StreamReader(fs3);
			ArrayList ar=new ArrayList();
			string msg=sw3.ReadLine();
			while(msg!=null)
			{
				ar.Add(msg);
				msg=sw3.ReadLine();
			}
			sw3.Close();
			fs3.Close();
			return ar;
		}
		//已读信息读写流;
		public void Ysendinfo(ShortMessage fo)
		{
			FileStream fs3=new FileStream("已读信息.txt",FileMode.Append);
			StreamWriter sw3=new StreamWriter(fs3);
			sw3.WriteLine("收信人:"+fo.Jnum);
			sw3.WriteLine("短信内容:"+fo.Minfo);
			sw3.WriteLine("发送人:"+fo.Fnum);
			sw3.WriteLine("发送时间:"+fo.Datetime);
			sw3.WriteLine("—————————————");
			sw3.Close();
			fs3.Close();
		}
		public ArrayList Yreadinfo()
		{
			FileStream fs4=new FileStream("已读信息.txt",FileMode.Open,FileAccess.Read);
			StreamReader sw4=new StreamReader(fs4);
			ArrayList ar=new ArrayList();
			string msg=sw4.ReadLine();
			while(msg!=null)
			{
				ar.Add(msg);
				msg=sw4.ReadLine();
			}
			sw4.Close();
			fs4.Close();
			return ar;
		}
	}
}

⌨️ 快捷键说明

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