Search Result

Collapse
6 results in 0.0013 seconds.
Keywords
Members
Tags
generics
  •  

  • Having a problem with a list<> of objects - any ideas?

    Hi,

    I have a class which looks like this (the class is then used to read back from a webservice)

    Code:
    class fred
    {
      string jim;
      string hilda;
      int eccles;
      bool crunn;
      double vodka;
    }
    Elsewhere in my code I have the following

    Code:
    public void doSomething()
    {
      List<fred> chunky = new List<fred>();
    ...
    See more | Go to post

  • Is this the correct behaviour (List<class> question)

    Hi,

    I enjoy trying new ways (to me) of doing getting my code to be more efficient. I'm currently working on a database system (front end to an access file with added bits) and have hit upon a problem.

    I have a number of tutors containing 3 pieces of information (name, email, mobile number). There can be loads of these and rather than muck around, I've come up with the following solution.

    My solution looks...
    See more | Go to post

  • how can i evaluate generic type in runtime in c#

    i need to evaluate generic type at runtime using
    Code:
    Type.GetType()

    Code:
    Type t  = Type.GetType("className");
    Table<t> table = dataContext.GetTable<t>();
    any ideas ?
    See more | Go to post

  • mmfarahat
    started a topic how can i evaluate generic type in runtime in c#
    in .NET

    how can i evaluate generic type in runtime in c#

    i need to evaluate generic type at runtime using
    Code:
    Type.GetType()

    Code:
    Type t  = Type.GetType("className");
    Table<t> table = dataContext.GetTable<t>();
    any ideas ?
    See more | Go to post

  • How to Load an Assembly of Generic Type <T> Dynamically ?


    How to Load the class "MyContent" dynamically ?
    I have 1 interface<T>, 1 abstract generic class<T> and 1 class. Check my code out:

    Code:
    public interface IMyObjectInterface{
    }
    public abstract MyAbstractObject : IMyObjectInterface{
    }
    public class MyObject : MyAbstractObject{
    }
    
    public interface IMyContentInterface<T>  where T : MyAbstractObject
    {
    ...
    See more | Go to post

  • CA1000: Why shouldn't I declare static members on generic types?

    I've written an abstract base type which uses generics to provide XML serialization and deserialization methods for use by its derived types, but I'm seemingly unable to write it in a way which completely satisfies FxCop code analysis. Here is the simplest form of the base class which reproduces the problem:

    Code:
    public abstract class XmlSerializableItem<T>
    {
    	public string ToXml()
    	{
    		XmlSerializer
    ...
    See more | Go to post
Working...