Skip to main content

Lindsay Donaghe's Library tagged C#   View Popular

11 Dec 08

Conditional-CSS

A tool that will generate browser specific CSS for you and package it all up in a C# HttpHandler (ASHX) so that it will deliver only the CSS for the browser that makes the request. Interesting idea to get around having to use browser hacks and still have all your code in one file for easy maintenance.

www.conditional-css.com - Preview

css tools generator C# php web development design crossbrowser optimization opensource

20 May 08

Linq: The Missing ToDictionary Extension Method Overload - Omer van Kloeten's .NET Zen

An extension method for getting a generic dictionary back from a collection of KeyValuePairs... just a bit of a shortcut from using the overload with two params, but handy.

weblogs.asp.net/...6121417.aspx - Preview

generics C# .Net codesnippets

  • public static Dictionary<TKey, TValue> ToDictionary<TKey, TValue>(this IEnumerable<KeyValuePair<TKey, TValue>> enumeration)
    {
    // Check to see that enumeration is not null
    if (enumeration == null)
    throw new ArgumentNullException("enumeration");

    return enumeration.ToDictionary(item => item.Key, item => item.Value);
    }
14 May 08

Yield and generics rock! - Tales from the Evil Empire

How to create a filter for generic lists (or other IEnumerable objects) without creating a temporary list first. Illustrates how to use the yield statement as well and create your own generic enumerator.

weblogs.asp.net/...223531.aspx - Preview

C# .Net codesnippets development generics

  • public sealed class FilteredEnumerable<T> : IEnumerable<T>, IEnumerable {

      private IEnumerable<T> _enumerable;
      private Predicate<T> _filter;

      public FilteredEnumerable(IEnumerable<T> enumerable, Predicate<T> filter) : base() {
        _enumerable = enumerable;
        _filter = filter;
      }

      IEnumerator<T> IEnumerable<T>.GetEnumerator() {
        foreach (T item in _enumerable) {
          if (_filter == null || _filter(item)) {
            yield return item;
          }
        }
      }

      IEnumerator IEnumerable.GetEnumerator() {
        return (IEnumerator)(((IEnumerable<T>)this).GetEnumerator());
      }
    }
  • string[] stringsToFilter = new string[] {"Red", "Green", "Blue", "Pink"};
    Predicate<string> filter = delegate(string stringToFilter) {
      return (stringToFilter.IndexOf('e') != -1);
    };
    filteredStrings = new FilteredEnumerable<string>(stringsToFilter, filter);

Microsoft Live Labs : Volta

A library that is similar to RJS in Ruby on Rails. It lets you write code in C# which can be spilt into tiers. The client tier is translated into the equivalent Javascript. Still a CTP and not sure how it fits in with ASP.Net (or if it does) yet.

labs.live.com/volta - Preview

javascript web development microsoft beta library downloads C# .Net

13 May 08

Script#

An IDE tool for C# that compiles into Javascript. Looks to be similar to RJS in Ruby on Rails. Not sure if it's related to Volka. I wish they'd build something that did this with jQuery.

projects.nikhilk.net/ScriptSharp - Preview

ide tools generator javascript c# downloads free extensions debugging web development

14 Apr 08

CodeProject: Load and display page contents asynchronously with full postback support. Free source code and programming help

A more Ajax-efficient version of the UpdatePanel - a PartialUpdatePanel. Less bandwidth usage than the regular update panel. It can also be set up to "instantiate" itself on the client instead of the server. Interesting use of an HTTPHandler to render the panel content.

www.codeproject.com/...PartialUpdatePanel.aspx - Preview

asp.net web development codesnippets downloads tutorials ajax c#

Steven Smith : Render User Control as String Template

A generics variation of Scott Guthrie's code to render ASCX controls as HTML for Ajax consumption.

aspadvice.com/...ontrol-as-String-Template.aspx - Preview

asp.net web development codesnippets generics C#

13 Apr 08

CodePlex.SpaceBlock - Home

An open-source Windows application written in .Net to manage your S3 account buckets and files. The most useful feature (that you don't have in S3 Fox) is the ability to generate a signed URL for sharing files with people.

www.codeplex.com/spaceblock - Preview

amazons3 opensource free downloads software .net c# development tools filestorage

09 Apr 08

The New Lambda Expressions Feature in C# 3.0

Code sample that compares performing the same function using anonymous functions, lambda and generic extensions. Good examples to see the differences in the syntax approaches.

www.developer.com/...3598381 - Preview

c# .Net microsoft codesnippets tutorials development lambda

21 Mar 08

Tip/Trick: Building a ToJSON() Extension Method using .NET 3.5 - ScottGu's Blog

Tutorial example of how to use object extension in .Net 3.5. Create a JSON convertor for an object. Interesting implications here, similar to prototyping in Javascript.

weblogs.asp.net/...sion-method-using-net-3-5.aspx - Preview

.net c# development microsoft oop tips tutorials

jsc (c# to javascript)

A "cross-compiler" that will take C# code and turn it into javascript, java or php. Not sure what the usefulness is yet but it's intriguing.

jsc.sourceforge.net - Preview

C# development downloads java javascript library php tools web

24 Aug 06

Threading in C# - Free E-book

  • Some good information here both in background information on threading and code snippets. - bluecockatoo on 2006-08-24
23 Aug 06

Open Source Software in C#

  • A website with a whole collection of C# resources for IDEs, code libraries, references, and coding tools all open source! - bluecockatoo on 2006-08-23

GDI+ FAQ main index

  • A good reference with tutorials and source code for GDI text and graphics manipulation in Winforms. - bluecockatoo on 2006-08-23
1 - 16 of 16
Showing 20 items per page

Diigo is about better ways to research, share and collaborate on information. Learn more »

Join Diigo