Skip to content

Instantly share code, notes, and snippets.

@SpaceShot
SpaceShot / gist:3152437
Created July 20, 2012 18:28
Linq query with customer order by to an anonymous type
XdsServicesDataContext xds = new XdsServicesDataContext();
var query = xds.SXAXDSCustomers.AsEnumerable().OrderBy(c => c.Oid, new OidComparer())
.Select( x =>
new {
Name = x.Name,
Oid = x.Oid,
UserId = x.UserId,
AllowAutoPatientRegistration = x.AllowAutoPatientRegistration,
MembershipUsersCollection = Membership.FindUsersByName(x.UserId)
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;
namespace ArenaGame
{
@SpaceShot
SpaceShot / gist:1050287
Created June 28, 2011 01:32
Game1 class
/// <summary>
/// LoadContent will be called once per game and is the place to load
/// all of your content.
/// </summary>
protected override void LoadContent()
{
// Create a new SpriteBatch, which can be used to draw textures.
spriteBatch = new SpriteBatch(GraphicsDevice);
gridTexture = Content.Load<Texture2D>("GridTemplate");