Linked Questions
                        11 questions linked to/from Converting from IEnumerable to List
                    
                
            
            
                56
            
            votes
        
        
            
                6
            
            answers
        
        
            
                104k
            
            views
        
        
            
            
            
        Casting IEnumerable<T> to List<T>
                    I was wondering if it is possible to cast an IEnumerable to a List. Is there any way to do it other than copying out each item into a list?
                
            
       
        
            
                9
            
            votes
        
        
            
                2
            
            answers
        
        
            
                30k
            
            views
        
        
            
            
            
        How I can convert System.Collection.IEnumerable to List<T> in c#? [duplicate]
                    How I can convert System.Collection.IEnumerable to list in c#?
Actually I am executing a store procedure that is giving me ResultSets in System.Collection.IEnumerable and I want to convert that result ...
                
            
       
        
            
                -1
            
            votes
        
        
            
                1
            
            answer
        
        
            
                2k
            
            views
        
        
            
            
        Error "Cannot implicitly convert type "System.Collections.Generic.IEnumerable<int>' to 'System.Collections.Generic.List<int>' [duplicate]
                    I'm attempting to convert a list of numbers to a string and then later back to a list. Converting to a string works fine, but when I convert it back to the list, I get the error "Cannot implicitly ...
                
            
       
        
            
                0
            
            votes
        
        
            
                0
            
            answers
        
        
            
                77
            
            views
        
        
            
        Convert an IEnumerable of unknown <T> to a List [duplicate]
                    I have a method similar to this:
void Log(object value)
{
    if (value is IEnumerable && !(value is IList))
    {
        // Need to convert value to a list here
    }
    // ... Rest of ...
                
            
       
        
            
                8
            
            votes
        
        
            
                2
            
            answers
        
        
            
                12k
            
            views
        
        
            
            
            
        Linq IEnumerable<IGrouping<string, Class>> back to List<Class>
                    How can I turn the following statement back to List<DocumentData>
IEnumerable<IGrouping<string, DocumentData>> documents = 
                 documentCollection.Select(d => d)....
                
            
       
        
            
                1
            
            vote
        
        
            
                2
            
            answers
        
        
            
                2k
            
            views
        
        
            
            
        Invalid cast from IEnumerable to List
                    I'm working on a C# script within a Unity3D Project where I'm trying to take a list of strings and get a 2D list of the permutations. Using this answer's GetPermutations() in the following fashion:
...
                
            
       
        
            
                1
            
            vote
        
        
            
                0
            
            answers
        
        
            
                2k
            
            views
        
        
            
        AutoMapper throwing 'Sequence contains no elements' (InvalidOperationException)
                    I'm trying to project a list of entities directly from an IQueryable using AutoMapper to a dto, however it always seems to fail with an InvalidOperationException stating that The sequence contains no ...
                
            
       
        
            
                0
            
            votes
        
        
            
                3
            
            answers
        
        
            
                330
            
            views
        
        
            
            
        Change normal loop to Parallel loop
                    I have the following code:
static void Main(string[] args)
{
   TaskExecuter.Execute();
}
class Task
{
        int _delay;
        private Task(int delay) { _delay = delay; }
        public void ...
                
            
       
        
            
                0
            
            votes
        
        
            
                1
            
            answer
        
        
            
                441
            
            views
        
        
            
            
            
        How Can I create objects of List<MyClass> dynamically?
                    How I can create Objects of MyClass Dynamically? I have nested lists, I will get the count of nested lists from my DataTable, so I don't know how many objects I need.
I am working inside loop.
Can I ...
                
            
       
        
            
                0
            
            votes
        
        
            
                1
            
            answer
        
        
            
                373
            
            views
        
        
            
            
        Manipulate ItemSource with a converter and return new list
                    I have a list with a converter like so
   <ListView ItemsSource="{Binding Availability, Converter={StaticResource AvailabilityConverter}}">
                <ListView.ItemTemplate>
        ...
                
            
       
        
            
                -1
            
            votes
        
        
            
                2
            
            answers
        
        
            
                84
            
            views
        
        
            
            
        c# instantiate a List<T> using AS ... beginner question
                    I am in the early stages of learning c# and am currently "fixing" a project (as an exercise). 
I've come across this code but I can't make sense of it. 
List<CartLine> cartList = Lines as List&...