using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace WindowsApplication11
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
/// <summary>
/// 此处建议配置在WEB.CONFIG文件中,此程序是服务器端,只能运行在OCS2007服务器上
/// </summary>
public string NotificationText = "发消息测试qqqq!"; ///消息内容
public string DistributinName = "sip:huy@fy.com";//发送人地址,此处已经更正为个人用户,但没有判断该用户是否在线,以及在线的状态
string ServerFqdn = "admin.fy.com";//ocs2007服务器的fqdn地址
string NumberofServerToServerConnections = "4";//服务器的连接数,建议设置4-6
string BroadcastImSipUri = "sip:admin@fy.com";//使用发送消息的管理员的sip地址
bool Tls = true;//如果设置的5061端口必须将此设置为true,如果走的是5060端口,需将此设置为false
private void button1_Click(object sender, EventArgs e)
{
RTCSendMessage.LoginOC A = new RTCSendMessage.LoginOC();
A.login(NotificationText, DistributinName, ServerFqdn, NumberofServerToServerConnections, BroadcastImSipUri, Tls);
}
}
}