unit WinForm1;
interface
uses
System.Drawing, System.Collections, System.ComponentModel,
System.Windows.Forms, System.Data,
TecCom,
TecCom.OpenMessaging,
TecCom.OpenMessaging.dto,
TecCom.OpenMessaging.Caller,
//TecCom.OpenMessaging.order,
TecCom.OpenMessaging.Order.TXML.V4_1.Order,
TecCom.OpenMessaging.Order.TXML.V4_1.Common,
TecCom.OpenMessaging.Warranty,
TecCom.OpenMessaging.localhost,
SysUtils
;
type
TWinForm1 =
class(System.Windows.Forms.Form)
{$REGION 'Vom Designer verwalteter Code'}
strict private
/// <summary>
/// Erforderliche Designervariable.
/// </summary>
Components: System.ComponentModel.Container;
Button1: System.Windows.Forms.Button;
RichTextBox1: System.Windows.Forms.RichTextBox;
/// <summary>
/// Erforderliche Methode zur Unterstützung des Designers -
/// ändern Sie die Methode nicht mit dem Quelltext-Editor
/// </summary>
procedure InitializeComponent;
procedure Button1_Click(sender: System.
Object; e: System.EventArgs);
{$ENDREGION}
strict protected
/// <summary>
/// Ressourcen nach der Verwendung bereinigen
/// </summary>
procedure Dispose(Disposing: Boolean);
override;
private
{ Private-Deklarationen }
order : TxmlOrder;
oi :
Array[0..1]
of OrderItemType;
pn :
Array of ProductName;
fc : FunctionCaller;
fcr : FunctionCallRequest;
pd :
Array of ParameterData;
resp : FunctionCallResponse;
OrderResponse : TxmlOrdRsp;
public
constructor Create;
end;
[assembly: RuntimeRequiredAttribute(TypeOf(TWinForm1))]
implementation
{$AUTOBOX ON}
{$REGION 'Vom Windows Form-Designer erzeugter Code'}
/// <summary>
/// Erforderliche Methode zur Unterstützung des Designers --
/// ändern Sie die Methode nicht mit dem Quelltext-Editor
/// </summary>
procedure TWinForm1.InitializeComponent;
begin
Self.Button1 := System.Windows.Forms.Button.Create;
Self.RichTextBox1 := System.Windows.Forms.RichTextBox.Create;
Self.SuspendLayout;
//
// Button1
//
Self.Button1.Location := System.Drawing.Point.Create(88, 232);
Self.Button1.
Name := '
Button1';
Self.Button1.TabIndex := 0;
Self.Button1.Text := '
Button1';
Include(Self.Button1.Click, Self.Button1_Click);
//
// RichTextBox1
//
Self.RichTextBox1.Location := System.Drawing.Point.Create(64, 64);
Self.RichTextBox1.
Name := '
RichTextBox1';
Self.RichTextBox1.TabIndex := 1;
Self.RichTextBox1.Text := '
RichTextBox1';
//
// TWinForm1
//
Self.AutoScaleBaseSize := System.Drawing.Size.Create(5, 13);
Self.ClientSize := System.Drawing.Size.Create(292, 273);
Self.Controls.Add(Self.RichTextBox1);
Self.Controls.Add(Self.Button1);
Self.
Name := '
TWinForm1';
Self.Text := '
WinForm1';
Self.ResumeLayout(False);
end;
{$ENDREGION}
procedure TWinForm1.Dispose(Disposing: Boolean);
begin
if Disposing
then
begin
if Components <>
nil then
Components.Dispose();
end;
inherited Dispose(Disposing);
end;
constructor TWinForm1.Create;
begin
inherited Create;
//
// Erforderlich für die Unterstützung des Windows Forms-Designers
//
InitializeComponent;
//
// TODO: Fügen Sie nach dem Aufruf von InitializeComponent Konstruktorcode hinzu.
//
end;
procedure TWinForm1.Button1_Click(sender: System.
Object; e: System.EventArgs);
var
TempAnfrage :
String;
TempAntwort :
String;
AnzahlAntworten : Integer;
begin
order.OrderHeader.OrderType := OrderTypeIDs.Order;
order.OrderHeader.OrderFunction := OrderFunctionTypes.Original;
order.OrderHeader.BuyerParty.PartyNumber.Qualifier := TecCom.OpenMessaging.Order.TXML.V4_1.Common.PartyNumberTypeQualifiers.SupplierNumber;
order.OrderHeader.BuyerParty.PartyNumber.PartyNumberValue := '
4712';
order.OrderHeader.SellerParty.PartyNumber.Qualifier := TecCom.OpenMessaging.Order.TXML.V4_1.Common.PartyNumberTypeQualifiers.BuyerNumber;
order.OrderHeader.SellerParty.PartyNumber.PartyNumberValue := '
32';
order.OrderHeader.OrderIssueDate.DateValue.DateValue := now;
order.OrderHeader.OrderProcessing.DispatchMode := DispatchModes.Normal;
order.OrderHeader.Currency := '
EUR';