Archive for April 2008

 
 

WPF performance profiling tools

The WPF Performance Suite is a set of performance profiling tools that allow you to analyze the runtime behavior of your WPF application.

This suite includes the following tools:

  • Perforator - for analyzing rendering behavior.
  • Visual Profiler - for profiling the use of WPF services, such as layout and event handling, by elements in the visual tree.
  • Working Set Analyzer - for analyzing the working set characteristics of your application.
  • Event Trace - for analyzing events and generating event log files.
  • ETW Trace Viewer - Record, display, and browse Event Tracing for Windows (ETW) log files in a WPF user-interface format.

The screenshot below is presenting how to Visual Profiler tool looks like:

Download WPF Performance Suite (x86 version)

7 free online editors for your asp.net site (part 2)

This is second part of a two-part article about free online editors.The first part of article can be found here

widgEditor

widgEditor is an easily installed, easily customizable WYSIWYG editor for simple content. It replaces existing textareas with an improved editing pane using JavaScript .

Download widgEitor

Demo

JWYSIWYG

This plugin is an inline content editor to allow editing rich HTML content on the fly.

Download JWYSIWYG

Demo

NicEdit

NicEdit is a Lightweight, Cross Platform, Inline Content Editor to allow easy editing of web site content on the fly in the browser.NicEdit Javascript integrates into any site in seconds to make any element/div editable or convert standard textareas to rich text editing.

Download NicEdit

Demo

Whizzywig

It allows to create rich, formatted text through a web form. It actually creates HTML (or xhtml, if you prefer) .Whizzywig is cross-browser: it is written in Javascript, which will run in nearly all web browsers.

Download Whizzywig

Demo

Yahoo! UI Text Editor

The Rich Text Editor is a UI control that replaces a standard HTML textarea. It allows for the rich formatting of text content, including common structural treatments like lists, formatting treatments like bold and italic text, and drag-and-drop inclusion and sizing of images. The Rich Text Editor’s Toolbar is extensible via a plugin architecture so that advanced implementations can achieve a high degree of customization.

Download Yahoo!UI Text Editor

Examples

markItUp!

markItUp! is a JavaScript plugin built on the jQuery library. It allows you to turn any textarea into a markup editor. Html, Textile, Wiki Syntax, Markdown, BBcode or even your own Markup system can be easily implemented.

Download martkUp!

Demo

Explore Silverlight project hierarchy with Silverlight Spy 2

Use the built-in browser to navigate to a web page. Silverlight Spy will automatically pick up any Silverlight application embedded in the page and display it in the XAML Explorer. The XAML Explorer presents the UI element structure of a Silverlight application. Explore the structure and view and edit the details of the selected UI element in the Details pane.

 

 

 

 

Features

  • Convenient XAML UI element explorer
  • XAML object property grid allows for getting and settings object property values
  • Regeneration of XAML based on the UI element structure
  • Statistics of used objects
  • Statistics of used resources (images, video, fonts, etc.)
  • UI element preview
  • Extensive search
  • Event Monitor
  • XAP package inspection
  • HTTP monitor

 

Download Silverlight Spy 2

 

Note: You must download and register(regsvr32) csexwb2 component before installing Silverlight Spy 2

Sorting System.Collections.Generic.List<T>

This post shows the sorting technique using anonymous delegate that can be implemented in any custom type generic list based on the selected property.For sorting any custom type the class must implement the System.IComparable interface. Now let me assume you have a Person class and if you want to sort the list of person objects then you must implement System.IComparable interface and write the logic of how our person object is to be sorted in the CompareTo method

using System;
namespace ConsoleApplication1
{
    class Person : IComparable
    {
        public Person(string firstName, int age)
        {
            FirstName = firstName;
            Age = age;
        }
        public string FirstName
        {
            get;
            set;
        }
        public int Age
        {
            get;
            set;
        }
        // sorting in ascending order      
        #region IComparable Members
        public int CompareTo(object obj)
        {
            var person = (Person) obj;
            return FirstName.CompareTo(person);
        }
        #endregion
    }
}

But you can simplify the sorting just by using the anonymous delegate as shown bellow and you don’t need to implement IComparable interface

var persons = new List<Person>
                    {
                        new Person("Tom", 30),
                        new Person("Harry", 55)
                    };
// sort in ascending order
persons.Sort(delegate(Person person0, Person person1)
                    {
                        return person0.FirstName.CompareTo(person1.FirstName);
                    });
// sort in descending order
persons.Sort(delegate(Person person0, Person person1)
                    {
                        return person1.FirstName.CompareTo(person0.FirstName);
                    });

Technorati tags: generic, c#, code

Must Have Tool for ASP.NET Developer

NetFXHarmonics DevServer is a web server hosting environment built on .NET 3.5 using WPF, WCF, and LINQ technologies that allows multiple instances of VS-like web servers to run in parallel. NetFXHarmonics DevServer also includes tracing capabilities for monitoring view status code, date/time, URL, POST data , response data, request headers, response headers, as well as parsed ViewState and Control state for both the request and response, visually enhanced HTTP status codes, IP binding modes for both local-only as well as remote access, and easy to use XML configuration. You can trace text specific files like HTML, CSS, JavaScript, JSON, XAML, Text, and SOAP and their content.

 

 

Download NetFXHarmonics DevServer

DevServer Announcement and Overview

 

[Via David Bet'z Blog]


Page 1 of 212