Thanks Johan
Have tried with lost of hope but bugger, still the same
See attached pic - also this is the current code:
using System.Windows.Forms
#using System.Drawing
#using System.LinQ
#using MYOB.AccountRight.SDK
#using MYOB.AccountRight.SDK.Services
#using MYOB.AccountRight.SDK.Services.GeneralLedger
#using MYOB.AccountRight.SDK.Contracts
//USING MYOB.AccountRight.SDK
//USING MYOB.AccountRight.SDK.Services
//USING MYOB.AccountRight.SDK.Contracts
CLASS BasicForm INHERIT System.Windows.Forms.Form
PROTECT oTextBox AS System.Windows.Forms.TextBox
PROTECT oOKButton AS System.Windows.Forms.Button
// User code starts here (DO NOT remove this line) ##USER##
CONSTRUCTOR()
SUPER()
SELF:InitializeForm()
RETURN
METHOD InitializeForm() AS VOID
// IDE generated code (please DO NOT modify)
SELF:oTextBox := System.Windows.Forms.TextBox{}
SELF:oOKButton := System.Windows.Forms.Button{}
SELF:SuspendLayout()
SELF:ClientSize := System.Drawing.Size{392 , 264}
SELF:Location := System.Drawing.Point{100 , 100}
SELF:Name := "BasicForm"
SELF:Text := "Basic form application"
SELF:oTextBox:Location := System.Drawing.Point{8 , 48}
SELF:oTextBox:Name := "TextBox"
SELF:oTextBox:Size := System.Drawing.Size{341 , 20}
SELF:oTextBox:TabIndex := 1
SELF:Controls:Add(SELF:oTextBox)
SELF:oOKButton:Click += SELF:OKButtonClick
SELF:oOKButton:Location := System.Drawing.Point{280 , 232}
SELF:oOKButton:Name := "OKButton"
SELF:oOKButton:Size := System.Drawing.Size{104 , 24}
SELF:oOKButton:TabIndex := 0
SELF:oOKButton:Text := "&OK"
SELF:Controls:Add(SELF:oOKButton)
SELF:ResumeLayout()
RETURN
METHOD OKButtonClick(sender AS OBJECT , e AS System.EventArgs) AS VOID
//SELF:Close()
SELF:OKButtonClick2()
// SELF:oTextBox:Text := "Ok"
RETURN
METHOD OKButtonClick2() AS VOID
VAR configuration := ApiConfiguration{"
http://localhost:8080/accountright"}
VAR cfService := CompanyFileService{configuration}
VAR companyFiles := cfService.GetRange()
SELF:oTextBox:Text :="Company Files set"
VAR companyFile := companyFiles.FirstOrDefault({x => Version{x:ProductVersion} >= Version{"2013.3"}})
VAR credentials := CompanyFileCredentials{"Administrator","muffin023H"}
VAR accountService := AccountService{configuration}
VAR accounts := accountService.GetRange(companyFile,NULL,credentials,NULL)
RETURN
END CLASS
- XIDE_LastError.JPG (65.05 KiB) Viewed 502 times