2010-12-08 27 views
0

我的公司希望我在solomon中創建一個自定義屏幕以從數據庫中的表中加載一些數據。Dynamics Solomon Customization

他們說使用visual studio.net,我看到使用VBA的手冊。

我應該使用什麼? VBA或視覺工作室5?

如何創建新的應用程序?

回答

0

我們得到了我們客戶的類似要求。我們正在使用Dynamics Solomon 2011.經過一番研究,我們發現我們需要先安裝VS 2008來創建開發環境,然後再安裝Solomon。在VS之後安裝Solomon將在Visual Studio中爲Solomon開發設置一些項目模板。

https://community.dynamics.com/product/sl/f/35/t/80585.aspx

有一些談判也是VS 2010的動態所羅門開發時,不建議使用。

我相信還有一個SDK for Dynamics Solomon,您可以在您的應用程序中使用它來連接Solomon數據庫並使用數據對象。我們沒有嘗試這個,但我們發現一些參考文獻討論了使用此SDK開發代碼。

http://www.microsoftdynamicsforums.com/forums/forum_posts.asp?TID=191&title=solomon-Object-model-code

下面是使用所羅門SDK示例代碼:

using System.Collections.Generic; 
using System.ComponentModel; 
using System.Data; 
using System.Drawing; 
using System.Text; 
using System.Windows.Forms; 
using Microsoft.Dynamics.SL.ObjectModel; 
using System.Threading; 
using System.Runtime.InteropServices; 




namespace LoginSL 
{ 
    class Program 
    { 
     [DllImport("kernel32")] 
     static extern void Sleep(uint dwMilliseconds); 
     public static Microsoft.Dynamics.SL.ObjectModel.SIVToolbar sivTB; 
     public static Microsoft.Dynamics.SL.ObjectModel.SIVApplication sivApp; 

     static void Main(string[] args) 
     { 

      sivTB = new SIVToolbar(); 


      sivTB.Login("servername", "systemdb", "company", "username", "password"); 

      sivApp = sivTB.StartApplication("9850000.exe"); 
      sivApp.Visible = true; 

      string datafile = "C:\\0101000.DTA"; 
      string ctrlfile = "C:\\0101000.ctl"; 
      string outfile = "C:\\0101000.log"; 
      //In C# "\\" is the predefined escape sequence for backslash. 

      sivApp.Controls["cdata"].Value = (datafile.ToUpper()); 
      sivApp.Controls["cfiletype"].Value = "ASCII"; 
      sivApp.Controls["cscreen"].Value = "0101000"; 

      sivApp.Controls["ccontrol"].Value = (ctrlfile.ToUpper()); 
      sivApp.Controls["coutput"].Value = (outfile.ToUpper()); 
      sivApp.Controls["cBegProcessing"].Value = true; 

      Sleep(5000); //remove the comment marks at the beginning of this line for workaround 


      sivApp.Quit(); 
      sivApp.Dispose(); 

      //GC.Collect(); 
      //GC.WaitForPendingFinalizers(); 
      //GC.Collect(); 

      Sleep(5000); //remove the comment marks at the beginning of this line for workaround 

      sivTB.Logout(); 
      sivTB.Quit(); 
      sivTB.Dispose(); 


      //GC.Collect(); 
      //GC.WaitForPendingFinalizers(); 
      //GC.Collect(); 
      //MessageBox.Show("TI is complete"); // Displays complete message 

     } 
    } 

    }