【发布时间】:2014-07-22 03:37:00
【问题描述】:
我继承了一些代码,当我尝试运行代码时收到上述错误消息。下面是代码:
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
namespace Scripting
{
[CompilerGenerated]
[Guid("C7C3F5A0-88A3-11D0-ABCB-00A0C90FFFC0")]
[TypeIdentifier]
[ComImport]
public interface IDrive
{
[DispId(0)]
[IndexerName("Path")]
string this[] { [DispId(0)] get; } //The error is here//
[DispId(10009)]
int SerialNumber { [DispId(10009)] get; }
[DispId(10007)]
string VolumeName { [DispId(10007)] get; [DispId(10007)] set; }
[SpecialName]
[MethodImpl(MethodCodeType = MethodCodeType.Runtime)]
void _VtblGap1_7();
[SpecialName]
[MethodImpl(MethodCodeType = MethodCodeType.Runtime)]
void _VtblGap2_1();
}
}
我是 C# 新手,想知道缺少什么参数。
我无法询问原始编码员。任何帮助将不胜感激。
【问题讨论】:
-
你能指出抛出这个错误的行号吗
标签: c#