2011-11-14 51 views
0

我試圖使用此代碼來開發自己的上下文菜單處理程序,我的應用程序:http://www.codeproject.com/KB/shell/ratingcolumn.aspxC#的ContextMenu處理器

但是什麼都沒有發生。然後我試圖只是編譯代碼,構建DLL和使用

regasm pathToDLL /codebase 

進行註冊,這是我得到的答覆

RegAsm : warning RA0000 : Registering an unsigned assembly with /codebase can ca 
use your assembly to interfere with other applications that may be installed on 
the same computer. The /codebase switch is intended to be used only with signed 
assemblies. Please give your assembly a strong name and re-register it. 
Types registered successfully 

但是新文件評級菜單中沒有出現(試圖重新啓動窗口,刷新關聯,菜單,一切)。我錯過了什麼嗎?我應該如何註冊DLL?

+2

似乎你會得到更好的答案,如果問直接作者的文章。 – Tigran

回答

1

有些人報告說,當您使用RegAsm和未簽名的程序集時,會得到錯誤的否定結果(類型註冊成功,但類型實際上未成功註冊)。

看到這個職位: Regasm and Com Interop false negatives

我認爲第一步你應該簽署您的集會,並100%肯定你註冊。 然後你應該仔細檢查你公開的COM對象是什麼類型。

希望這會有所幫助。

+0

嘗試註冊它並從該鏈接跳過 - 沒有工作。註冊後是否需要刷新?無論如何,是否有一種方法可以在客戶端計算機上執行此操作(從使用代碼的UAC權限的應用程序)? – n1tr0