Sage 300 .NET销售订单更新

时间:2018-04-24 06:05:11

标签: sage-300

如何跟踪在针对Sage 300 ERP 2018运行VB.Net程序时遇到的错误?我在下面的oeDetail.Update()命令中收到System.Runtime.InteropServices.COMException错误。我有一个会话并组成了观点。我从VBA宏(它工作的地方)复制代码

    oeHeader.Fields.FieldByName("DRIVENBYUI").SetValue("0", False)    ' Driven by UI

    ' Search OE
    oeHeader.Init()
    oeHeader.Fields.FieldByName("ORDUNIQ").SetValue("1985", False)     ' Order Number
    oeHeader.Order = 1
    Dim res = oeHeader.Read(False)

    ' Update Detail
    oeDetail.Fields.FieldByName("LINENUM").SetValue("32", False)
    oeDetail.Read(False)
    ' Quantity Ordered
    oeDetail.Fields.FieldByName("QTYORDERED").SetValue("5.0000", False)    ' Quantity Ordered
    oeDetail.Update()

    oeHeader.Fields.FieldByName("OECOMMAND").SetValue("4", False)
    oeHeader.Process()
    oeHeader.Update()

由于

1 个答案:

答案 0 :(得分:0)

将整个内容粘贴在try / catch块中。然后在catch块中执行以下操作:

module sevensegment (input [3:0] bcd, output reg [6:0] seg);
always @ (*)
      case(bcd)
      0: seg = 7’b0111111; 
      1: seg = 7’b0000110;   
      2: seg = 7’b1011011;
      3: seg = 7’b1001111;
      4: seg = 7’b1100110;
      5: seg = 7’b1101101;
      6: seg = 7’b1111101;
      7: seg = 7’b0000111;
      8: seg = 7’b1111111;
      9: seg = 7’b1101111;
      default:  seg = 7’b0000000;
    endcase  
endmodule

“ accpacSession.Errors [i] .Message”行是提取内部Sage消息的地方。