我正在尝试通过 Quickbooks POS SDK 将 C# 程序与 Quickbooks POS 集成。我安装了 Quickbooks、Quickbooks SDK、Quickbooks POS 和 Quickbooks POS SDK。
当下面的代码点击“sessionManager.BeginSession("");” 我收到错误消息“读取 btnHelp.BorderColorSelected:Property BorderCo 时出错”。不是以 BorderCo 结尾的错字。
有人请帮忙!
using System;
using System.Net;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data;
using System.IO;
using Interop.qbposfc3;
namespace POSTest2
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void CustomerAdd()
{
QBPOSSessionManager sessionManager = new QBPOSSessionManager();
IMsgSetRequest request = sessionManager.CreateMsgSetRequest(3, 0);
request.Attributes.OnError = ENRqOnError.roeContinue;
BuildItemInventoryAddRq(request);
sessionManager.OpenConnection("appID", "Application");
sessionManager.BeginSession("");
IMsgSetResponse response = sessionManager.DoRequests(request);
sessionManager.EndSession();
sessionManager.CloseConnection();
}
private void BuildItemInventoryAddRq(IMsgSetRequest request)
{
IItemInventoryAdd ItemInventoryAddRq = request.AppendItemInventoryAddRq();
ItemInventoryAddRq.ALU.SetValue("M9ine");
}
private void button1_Click(object sender, EventArgs e)
{
CustomerAdd();
}
}
}