using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Net;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Xml;
namespace toSAPPOWebService
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
listBox1.Items.Clear();
//创建一个输入参数对象
com.bngrp.podev.dt_JK0088 input = new com.bngrp.podev.dt_JK0088();
//控件提供参数
input.UNAME = textBox1.Text;
//创建一个接口调用对象
com.bngrp.podev.si_JK0088_donet_senderService jk0088 = new com.bngrp.podev.si_JK0088_donet_senderService();
//PO服务器要求一个用户名,密码
jk0088.Credentials = new NetworkCredential("poservice", "password");
//调用接口,得到返回表
com.bngrp.podev.dt_JK0088_respReturntable[] rt = jk0088.si_JK0088_donet_sender(input);
//遍历返回的消息
foreach (com.bngrp.podev.dt_JK0088_respReturntable line in rt)
{
listBox1.Items.Add(line.TCODE.ToString());
}
}
}
}
-==================================