|
WIN設置代理人審核未成功? |
觀看回應
|
|
請註意以下地方: 1. 代理的起始日期、起始時間、終止日期、終止時間。 2. 是否有指定流程,如果有指定流程,則只有特定流程會啟動代理機制。 3. 平行代理如果為Y,代表兩個人都會收到待辦事項。
|
|
|
|
工作流表單中SYS_TodoList的Status欄位中所有值的含義是什麼? |
觀看回應
|
|
'N':新流程建立. 'P':流程過程中. 'Z':流程結案. 'X':流程作廢. 'F':通知 'NF':被取回 'NR':被退回 'A':加簽
|
|
|
|
C#語法改寫VB語法,SERVER METHOD範例? |
觀看回應
|
|
原文C# ServerMethod public object CallTest(object[] objParam) { string str = objParam[0].ToString(); string sql= "select avg(UnitPrice) as AvgPrice from [order details] Where ProductID="; sql = sql + str; DataSet Tmp = ExecuteSql("view", sql, true); string retval=Tmp.Tables[0].Rows[0][ "AvgPrice"].ToString(); Thread.SlEEP(5000); object ret; ret = new object[] { 0, retval}; return ret; }
改寫為VB: Public Function CallTest(ByVal objParam() As Object) As Object() Dim str As String str = objParam(0).ToString() Dim sql As String sql = "select avg(UnitPrice) as AvgPrice from [order details] Where ProductID=" sql = sql + str Dim tmp As DataSet tmp = ExecuteSql("view", sql, True) Dim retval As String retval = tmp.Tables(0).Rows(0)("AvgPrice").ToString() System.Threading.Thread.SlEEP(5000) Dim ret As Object ret = New Object() {0, retval} Return ret End Function
|
|
|
|
請問 VB.NET Client如何 call ServerMethod? |
觀看回應
|
|
例如:Server端的module為S001.dll,裏面有一個Server Method名稱為TestMethod 同步的情況: Dim param(2) As Object param(1) = "param1" param(2) = "param2" Dim obj = Srvtools.CliUtils.CallMethod("S001", "TestMethod", param) 異步的情況: Public Sub CallBack(ByVal obj1() As Object) MsgBox(obj1(0).ToString + " --" + obj1(1)) End Sub
Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Dim obj1(2) As Object obj1(1) = "1" obj1(2) = "2" Srvtools.CliUtils.AsyncCallMethod("sTDORDER", "MyCount", obj1, AddressOf CallBack) End Sub
|
|
|
|
使用ExcelPlate,如何不要透過Excel即可直接印表? |
觀看回應
|
|
可以在ExcelPlate的AfterOutput事件中加入印表的程式,如下: using System.Reflection; using System.Runtime.InteropServices; private void excelPlate1_AfterOutput(object sender, EventArgs e) { Excel.Application objExcel = new Excel.Application(); objExcel.Visible= false; Excel.Workbook objWorkBook = objExcel.Workbooks.Open(excelPlate1.FilePath, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value, Missing.Value); try { objWorkBook.PrintOut(1, 1, 1, false, Missing.Value, Missing.Value, Missing.Value, Missing.Value); } finally { objExcel.Quit(); Marshal.ReleaseComObject(objExcel); Marshal.ReleaseComObject(objWorkBook); objExcel = null; objWorkBook = null; GC.Collect(); } } PrintOut為打印的函數,第一個參數是打印起始頁,第二個參數打印結束頁,第三個參數是打印的份數
|
|
|