Silverlight: Value does not fall within the expected range exception

前端 未结 4 667
臣服心动
臣服心动 2020-12-19 09:35

I am getting \"Value does not fall within the expected range exception\" when adding children to stack panel. This happens even when myStackPanel.Children.Count = 0 just be

4条回答
  •  猫巷女王i
    2020-12-19 10:08

    Seems to me that what you really want is an ItemsControl, you are not really using the capabilities of Silverlight:-

    
         
             
                 
                    
                       
                       
                    
                 
             
         
    
    

    then your func becomes:-

    public void func()
    {
        items.ItemsSource =  docDictionary[ID];
    }
    

提交回复
热议问题