private  _strings() as string
    Public  Property Item(ByVal Index As Integer) As string
        Get
            Return _strings
        End Get
    End Property这里是部分的VB代码,主要思想是:根据索引访问数组中的某一项,而不是返回数组。

解决方案 »

  1.   

    我不是说了吗!它不是把数组一起返回的,而是单个访问的。比如:DropDownList.Items(3)它并不是返回的整个DropDownList.Items,而只是DropDownList.Items(3)的第三项而已。你要是还不明白的话,我也没办法了。
      

  2.   

    麻烦你将你的代码写成C#的,Vb的我看不太明白
      

  3.   

    private StringCollection _strings = new StringCollection();
    [Category("MX"), Description("状态栏面板文本")]
    [Editor("System.Windows.Forms.Design.StringCollectionEditor, System.Design", "System.Drawing.Design.UITypeEditor, System.Drawing")]
    public StringCollection Strings
    {
    get
    {
    return _strings;
    }
    set
    {
    _strings = value;
    }
    }