using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;
namespace ImApi
{
class Program
{
static ImLib.ImApi imapi = null;
static void Main(string[] args)
{
imapi = new ImLib.ImApi("192.168.1.163");
//注册新帐号
System.Console.WriteLine(imapi.CreateUser("vvvvvvvv","sdcdscdcvvv","12345"));
//imapi.OnConnected += new ImLib.ImApi.Connected(imapi_OnConnected);
//imapi.Login("ceshi2", "ceshi2");
System.Console.ReadLine();
}
//连接成功后再发消息
static void imapi_OnConnected(object sender, EventArgs e)
{
System.Console.WriteLine("登陆成功");
imapi.SendMessage("ceshi1", "测试");
}
}
}
完整项目代码及编译后的类库下载地址:
https://pan.baidu.com/s/1kUW0uSf