string[] 必须要 new分配个长度 
比如 string[] strTitle = new string[5];

解决方案 »

  1.   

    string数组必须先 实例化 如:string[] strTitle = new string [n], n表示 这个数组的大小
    赋空值是 string[] strTitle = null
      

  2.   

    如果你长度不定 可以用 List<string>
      

  3.   

    我建议用 ArraryList 或者 用泛型如:
    public       string[]         getTitle 
            { 
                
                    get{ 
                            ArraryList al = new ArraryList()   ; 
                            int   i=0; 
                            scReader   dr   =   new   scReader("select   Title   from   news   "); 
                            while   (dr.Read()) 
                            { 
                                   al.add(dr["Title"].ToString()); 
                                  i++; 
                            } 
                            return     (string[])al     //这里要把al转换成字符型的 好象是这样弄的
                    } 
                    
                    
                    //dr.Close; 
            } 提供一个建议作为参考
      

  4.   

    没看到你初始化
    string[]   strTitle   ; 
    这只是声明而已。
      

  5.   

    使用数组就必须初始化长度,否则就使用List<string>