コード例 #1
0
        protected void Page_Load(object sender, EventArgs e)
        {
            using (IMoBContext context = new MoBContext())
            {
                //last 20 Artist records created
                var newArtistsQuery = (from m in context.Artists
                                       orderby m.CreateDate descending
                                       select m).Take(20);
                List <Artist> newArtistsList = newArtistsQuery.ToList <Artist>();

                NewArtistDataList.DataSource = newArtistsList;
                NewArtistDataList.DataBind();
            }
        }
コード例 #2
0
 public BandController(MoBContext context)
 {
     _context = context;
 }
コード例 #3
0
 public LookupListViewComponent(MoBContext db)
 {
     _db = db;
 }
コード例 #4
0
 public TagCloudViewComponent(MoBContext dbcontext)
 {
     _context = dbcontext;
 }
コード例 #5
0
 public LookupListViewComponent(MoBContext dbContext)
 {
     _dbContext = dbContext;
 }