uses MyProgram.MyNamespace in 'filepath/unit1.pas;otherpath/unit2.pas';
In this example, the namespace MyProgram.MyNamespace logically contains all the interface symbols from unit1 and unit2. Symbol names in a namespace must be unique, across all units in the namespace. In the example above, if unit1 and unit2 both define a global interface symbol named mySymbol, the compiler will report an error in the uses clause.
但是不管我怎樣試驗(yàn),重視編譯錯(cuò)誤,無(wú)法實(shí)現(xiàn)。
到目前為止,我還沒有找到如何引用delphi生成的dll的方法。因?yàn)槲乙辉赿elphi新的工程中添加一個(gè)(用Add reference菜單)delphi for .net編譯的dll,然后編譯,就會(huì)說(shuō)致命錯(cuò)誤,不能導(dǎo)入什么什么東西,請(qǐng)使用包,之類的。但是在VS.net中添加著dll卻沒有任何問題,程序也能正常運(yùn)行。
到目前為止只找到一個(gè)暫時(shí)的解決方案,就是不生成library,用package代替,這樣最終目標(biāo)文件也是dll,而且我在VS中也能正常調(diào)用。
新聞熱點(diǎn)
疑難解答
圖片精選
網(wǎng)友關(guān)注