bcb如何傳值給c#!? |
答題得分者是:ikk
|
好奇寶寶
一般會員 ![]() ![]() 發表:2 回覆:3 積分:1 註冊:2009-02-17 發送簡訊給我 |
不好意思第一次發文
如何把bcb運算得到的值傳給c#呢? ========舉例======== 我利用bcb做影像判別所獲得的圖是圖一 那我要傳一個值給c# 是利用c#呼叫bcb嗎? 是使用這個範例嗎? using System; using System.Diagnostics; using System.ComponentModel; namespace MyProcessSample { /// /// Shell for the sample. /// class MyProcess { // These are the Win32 error code for file not found or access denied. const int ERROR_FILE_NOT_FOUND =2; const int ERROR_ACCESS_DENIED = 5; /// /// Prints a file with a .doc extension. /// void PrintDoc() { Process myProcess = new Process(); try { // Get the path that stores user documents. string myDocumentsPath = Environment.GetFolderPath(Environment.SpecialFolder.Personal); myProcess.StartInfo.FileName = myDocumentsPath "\\MyFile.doc"; myProcess.StartInfo.Verb = "Print"; myProcess.StartInfo.CreateNoWindow = true; myProcess.Start(); } catch (Win32Exception e) { if(e.NativeErrorCode == ERROR_FILE_NOT_FOUND) { Console.WriteLine(e.Message ". Check the path."); } else if (e.NativeErrorCode == ERROR_ACCESS_DENIED) { // Note that if your word processor might generate exceptions // such as this, which are handled first. Console.WriteLine(e.Message ". You do not have permission to print this file."); } } } public static void Main() { MyProcess myProcess = new MyProcess(); myProcess.PrintDoc(); } } } |
ikk
尊榮會員 ![]() ![]() ![]() ![]() ![]() ![]() 發表:4 回覆:413 積分:768 註冊:2003-06-30 發送簡訊給我 |
|
好奇寶寶
一般會員 ![]() ![]() 發表:2 回覆:3 積分:1 註冊:2009-02-17 發送簡訊給我 |
|
好奇寶寶
一般會員 ![]() ![]() 發表:2 回覆:3 積分:1 註冊:2009-02-17 發送簡訊給我 |
|
ikk
尊榮會員 ![]() ![]() ![]() ![]() ![]() ![]() 發表:4 回覆:413 積分:768 註冊:2003-06-30 發送簡訊給我 |
|
好奇寶寶
一般會員 ![]() ![]() 發表:2 回覆:3 積分:1 註冊:2009-02-17 發送簡訊給我 |
本站聲明 |
1. 本論壇為無營利行為之開放平台,所有文章都是由網友自行張貼,如牽涉到法律糾紛一切與本站無關。 2. 假如網友發表之內容涉及侵權,而損及您的利益,請立即通知版主刪除。 3. 請勿批評中華民國元首及政府或批評各政黨,是藍是綠本站無權干涉,但這裡不是政治性論壇! |