我想创建.netmodule文件 [英] I want to create .netmodule file

查看:78
本文介绍了我想创建.netmodule文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在Java中使用.netmodule文件
我已经使用该命令创建了.netmodule文件.
C:>csc /t:module (ClassName).cs
如果(ClassName).cs与其他类独立是可以的

我想为下面的类生成.netmodule文件

C#

I want to use .netmodule file in java
I''ve already created .netmodule file using that command
C:>csc /t:module (ClassName).cs
It is ok if (ClassName).cs is independent with other class

I want to generate .netmodule file for below class

C#

namespace MIT.ISO8583Net.BusinessLogic
{
    public abstract class AbstractFieldMessage : IISOFieldMessage
    {
     public byte[] _packedData;
     public short _packedSize = 0;
     public AbstractFieldMessage()
     {
     }
     public AbstractFieldMessage(short size)
     {
         _packedData = new byte[size];
     }
        #region IMessage Members
       abstract public int Pack() ;

       public abstract int Unpack();

        //public byte[] PackedData
        //{
        //    get { return _packedData; }
        //    set { _packedData = value; }
        //}

        #endregion
    }
}



当我在VS2010命令提示符下编译时,
我收到此错误



When i complied in VS2010 command prompt,
I got this error

AbstractFieldMessage.cs(8,50): error CS0246: The type or namespace name
        'IISOFieldMessage' could not be found (are you missing a using directive
        or an assembly reference?)



我该怎么办?
请帮助我.



How can i do?
Please help me.

推荐答案

像错误状态一样,您缺少对IISOFieldMessage
的引用
OP问他如何使用命令行工具来做到这一点?

请参阅 csc文档 [ C#编译器选项 [ ^ ]在MSDN上
Like the error states, you are missing a reference to IISOFieldMessage

OP asked how can he do it using the command line tool?

See csc documentation[^] and C# compiler options [^] On MSDN


使用对IISOFieldMessage的引用进行编译:

Compile it with a reference to IISOFieldMessage :

csc /t:module (ClassName).cs /reference <assembly containing IISOFieldMessage>.<dll or exe>



干杯



Cheers


使用对IISOFieldMessage的引用对其进行编译:

Compile it with a reference to IISOFieldMessage :

csc /t:module (ClassName).cs /reference <assembly containing IISOFieldMessage>.dll/exe



干杯



Cheers


这篇关于我想创建.netmodule文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆