[問題] Add-in 裡這些method 不能用...
是C#的add-in
using System;
using Extensibility;
using EnvDTE;
using EnvDTE80;
...繁族不及備載
using Microsoft.VisualStudio.Shell;
using Microsoft.VisualStudio.Shell.Interop;
using System.Collections;
using System.Windows.Forms;
using System.IO;
~口卡口卡~ 直接跳到exec
public void Exec(string commandName, vsCommandExecOption executeOption,
ref object varIn, ref object varOut, ref bool handled)
{
handled = false;
if(executeOption == vsCommandExecOption.vsCommandExecOptionDoDefault)
{
if(commandName == "ProjectLauncher.Connect.ProjectLauncher")
{
DisplayLaunchForm();
TestStackFrames((DTE)(_applicationObject));
//主要測試
string string2 = " ";
string2 = (string)function_path.Pop();
//解釋: TestStackFrames((DTE)(_applicationObject));
//這個東西是針對 function_path (一個stack),我是把string資料存到裡面去
//問題就在這: 你們看下面幾行,我用了MessageBox.Show要去display function_path
//的東西 但是不行的~ ,連下面那個Show Hello? Form 也不行~
//Console 也不鳥我...
MessageBox.Show(string2);
string2 = (string)function_path.Pop();
MessageBox.Show("Hello? Form", "WinApp");
Console.WriteLine(string2);
handled = true;
return;
}
}
}
~口卡口卡~
************************************************************
是不是在add-in裡面不能用form的API/ 也不能用Console app 的
每個不同的project有各自的輸出函式? 不能混用?
And
因為我沒有辦法用debugger去看,所以我只能找類似printf 的方式去把local var.
show出來,...VS是不是沒有這種類似的功能阿 / \ 好苦阿...
Thanks for millions
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 140.115.178.77
→
07/17 21:01, , 1F
07/17 21:01, 1F
→
07/17 21:03, , 2F
07/17 21:03, 2F
→
07/17 23:27, , 3F
07/17 23:27, 3F
→
07/18 01:05, , 4F
07/18 01:05, 4F
→
07/18 01:06, , 5F
07/18 01:06, 5F
→
07/18 01:07, , 6F
07/18 01:07, 6F
→
07/18 01:07, , 7F
07/18 01:07, 7F
→
07/18 12:32, , 8F
07/18 12:32, 8F
C_Sharp 近期熱門文章
PTT數位生活區 即時熱門文章