[Home] [Recent] [Site Map] [SharePoint] [XBOX]

Volunteer night is Wednesday at Nexient (2 Bloor West, at Yonge). If you"d like to be one of the intelligent, wonderful, sexy people we call our volunteers then click through the picture and get in there!
Registration is filling up fast, so if you"re planning to come out, please get your name and e-mail address in today. Confirmations will go out prior to the event, note that the site does not display a confirmation message. Freebies from our sponsors are available for the first 200 peple through the door who registered on the site. If you"re not sure whether you can come Saturday, you"re welcome to "just show up" but will not be eligible for the free swag.
There will be 12 to 15 great sessions through the day from a stellar cast of presenters. You can get details about most of these on the website already, all will be there soon.
On Saturday, Check-in starts at 8:00am, and the first sessions start at 9:00am. For the last session, we"ll wrap up with a Roundtable Panel where you can throw questions at your favourite speakers. Then it"s on to the raffle (complete your evaluations!) where you"ll have a chance at one of many, many great prizes. Check-out is at 6:00pm, soon after which my Event Receivers will be firing up for beer.
See you there!
I"m starting to take a look at VS 2008 and writing down some things that are still "not there":
Are you kidding me?
Someone is not paying enough attention, or has their priorities screwed up.
I recently published a video on resizing Silverlight controls. I just observed an odd behavior in the Firefox browser when setting the height of the plugin to any percentage (10%, 50%, 100%). I can set the width to 100%, as the screenshot below indicates:

Notice the height is set to 100, not 100%. Now, if I change the height to 100%, this is what happens:

By setting the height to a percentage (of any number) in Firefox, my silverlight control disappears. If I set the height to a percentage in other browsers - the control behaves as it should. Anyone know why height percentage does not work in Firefox?
My recent article on DNS has been posted on the ASP.NET home page as article of the day. Yay!
Thanks team :)
October 29-30 is our annual GeneXus USA Event (Chicago IBM Innovation Center)
I"ll be there giving first of all an overview of GeneXus (coded name Rocha) and after in another talk I"ll be talking about Development of dynamic languages generators. We will show the current development stage of our Ruby Generator and obviously we are going to show you what kind of applications you could create with GeneXus Rocha.
If you want to join us http://www.genexus.com/usa/event
We have just released our first Beta for GeneXus with C# and Java generators and SQL, MySQL, DB2, Oracle support. Additionaly we have released our first CTP of our Ruby Generator.
You can try GeneXus Beta 1 here.
If you don"t know anything about GeneXus here you have our first online book, it is a good starting point to understand many of the concept behind GeneXus.
I"m a big fan of .NET Generics. In fact, I can"t believe I lived without them in .NET 1.1. Generics are pretty much the most powerful feature for C# 2.0. They allow you to define type safe data structures. They give a huge boost in performance, and they allow us to move away from DataTables and DataSets when it comes to collections of standard data.
Microsoft"s MSDN has a great article that explains more about generics. You can find it here.
What I intend to give you in this short blog is a quick refresher on the List<T>. I"ve always loved this strongly typed list, and I cannot work without it.
Let"s take the class Ninja (Now remember there"s a whole lot more to Ninjas than just their age and name):
*Note this isn"t the best made class, so please don"t quote me on this one :P
71 public class Ninja
72 {
73 public int _age;
74 public string _name;
75
76 public Ninja(int age, string name)
77 {
78 this._age = age;
79 this._name = name;
80 }
81 }
I"m now going to manually add a few Ninjas to my List:
18 //Let"s create our List.
19 //Remember this uses System.Collection.Generic
20 List<Ninja> people = new List<Ninja>();
21
22 people.Add(new Ninja(26, "Ryan Ternier"));
23 people.Add(new Ninja(23435, "You"));
24 people.Add(new Ninja(0, "Ryan"s New Kid"));
25 people.Add(new Ninja(4, "Xana"));
26 people.Add(new Ninja(4, "Hobbs"));
27 people.Add(new Ninja(-1, "Trogdor"));
I now have a Type Safe List. This list is a high efficiency killing machine... literally.
I"m going to use a StringBuilder to hold my HTML. If you don"t understand why, please be patient and look at this post regarding string efficiency.
Let"s see some code!
29 //now let"s have some fun.
30 System.Text.StringBuilder sb = new System.Text.StringBuilder();
31 sb.Append("<h1>List As Is</h1> using ForEach<br/> ");
32 sb.Append("<br/><ul>");
33 people.ForEach(delegate(Ninja p)
34 {
35 sb.Append(String.Format("<li>{0}, ({1})</li>", p._name, p._age));
36 });
37 sb.Append("</ul><br/>");
38
39 ///////////////////////////////////////
40 sb.Append("<h1>Age is greater or equal to 0</h1>using FindAll,and foreach<br/> ");
41 sb.Append("<br/><ul>");
42 List<Ninja> thoseAlive = people.FindAll(delegate(Ninja p)
43 {
44 return p._age >= 0;
45 });
46 thoseAlive.ForEach(delegate(Ninja p)
47 {
48 sb.Append(String.Format("<li>{0}, ({1})</li>", p._name, p._age));
49 });
50 sb.Append("</ul><br/>");
51 ////////////////////////////////////////
52 sb.Append("<h1>let"s Sort Them</h1>using Sort<br/> ");
53 sb.Append("<br/><ul>");
54 people.Sort(delegate(Ninja p1, Ninja p2)
55 {
56 return p1._name.CompareTo(p2._name);
57 });
58 people.ForEach(delegate(Ninja p)
59 {
60 sb.Append(String.Format("<li>{0}, ({1})</li>", p._name, p._age));
61 });
62 sb.Append("</ul><br/>");
63 /////////////////////////////////////////
64 lblTest.Text = sb.ToString();
There are many more functions on each List in the Generics Namespace. Most of them function the same as you see above. I would recommend getting your head wrapped around delegates because as soon as VS 2008 comes out they will be your best friend.
Ok, let"s look at the output.
You can see how nice they are. What is especially nice is when you have a List<t> of objects that have their own List<t> of more objects. Generics make it very easy to work with and play with these.
Remember that C# is also Managed Code, which means you can do the following:
83 public class FemaleNinja : Ninja
84 {
85 public string _husband;
86
87 public FemaleNinja(string husband, int age, string name)
88 : base(age, name)
89 {
90 this._husband = husband;
91 }
92 }
Let"s add it to the String Builder. I"ll use a regular ForEach here, checking the type of each "ninja" in my List.
65 FemaleNinja femaleNinja = new FemaleNinja("Ryan", 29, "Ange");
66 ninjas.Add(femaleNinja);
67 sb.Append("<h1>Get all Female Ninja</h1>using Foreach<br/> ");
68 sb.Append("<br/><ul>");
69 ninjas.ForEach(delegate(Ninja p)
70 {
71 if(p.GetType() == typeof(FemaleNinja))
72 sb.Append(String.Format("<li>{0}, ({1})</li>", p._name, p._age));
73 });
74 sb.Append("</ul><br/>");
75 sb.Append("</ul><br/>");
76
77 lblTest.Text = sb.ToString();
And here we go!
I really like this DataCalendar control that I found a while back and, even though it"s a few years old, I keep finding new uses for it.
I"m working on this little project that includes a feature for posting events (live auctions in this case). The project includes syndicating the event list through RSS but, the people using it didn"t really understand why that was cool. So, using the DataCalendar control, I created a little "look-at-what-RSS-can-do" demonstration that, to put it simply, "goes out to a bunch of auction web sites and copies all of the upcoming auctions to a calendar on my web site". Here"s what the example looked like.
Feel free to tinker with the example by using an RSS feed of your own choosing. Just change the "test" parameter like in this example that loads some blogs from one of my other sites.
Before you get started, you need to download the DataCalendar control.
NOTE: I created this calendar to display in my CommunityServer-based site but, it should be pretty easy to pick out the CS stuff if you want it "plain vanilla".
In the Default.aspx...
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="Auctions_Default" %> <%@ Register Assembly="DataCalendar" Namespace="DataControls" TagPrefix="cc1" %> <%@ Register TagPrefix="CS" Namespace="CommunityServer.Controls" Assembly="CommunityServer.Controls" %> <CS:MPContainer runat="server" id="Mpcontainer1" ThemeMasterFile="Master.ascx"> <CS:MPContent id="bcr" runat="server"> <div class="CommonContentArea"> <div class="CommonContent"> <CS:ContentPart runat="Server" contentname="CustomerAuctions" id="featuredContentPart" text="<div class="CommonSidebarArea"><h4 class="CommonSidebarHeader">Featured Item</h4><div class="CommonSidebarContent">Content Management is easy in Community Server! <p>Sign-in with your Admin account and double-click to edit me!</p></div></div>" /> <cc1:DataCalendar ID="dcAuctions" ShowNextPrevMonth="true" BackColor="white" DayField="TaskDate" Font-Names="verdana" NextPrevFormat="FullMonth" runat="server" Width="100%"> <SelectedDayStyle BackColor="ghostwhite" ForeColor="black" /> <OtherMonthDayStyle ForeColor="#999999" /> <NextPrevStyle Font-Size="10pt" Font-Underline="false" ForeColor="white" /> <DayHeaderStyle BackColor="lightgrey" ForeColor="black" Height="1px" /> <TitleStyle BackColor="black" Font-Bold="True" Font-Size="14pt" ForeColor="white" Height="35px" /> <SelectorStyle BackColor="#99CCCC" ForeColor="#336666" /> <WeekendDayStyle BackColor="ghostWhite" /> <DayStyle HorizontalAlign="left" ForeColor="dimgray" VerticalAlign="top" /> <itemtemplate> <a href="<%# Container.DataItem["link"] %>" style="display:block; font-size:70%; margin:2px; padding:2px; text-transform:capitalize; border: 1px solid goldenrod; display:block; background-color:AntiqueWhite; text-decoration:none;" title="Click for Details"> <%# Container.DataItem["Title"] %> </itemtemplate> <noeventstemplate> <br /><br /><br /><br /> </noeventstemplate> </cc1:DataCalendar> </div> </div> </CS:MPContent> </CS:MPContainer>
Then, wire it up (NOTE: this is just a bare example with no error handling):
In the Default.aspx.cs...
using System; using System.Data; using System.Configuration; using System.Collections; using System.Web; using System.Web.Security; using System.Web.UI; using System.Web.UI.WebControls; using System.Web.UI.WebControls.WebParts; using System.Web.UI.HtmlControls; using System.Xml.XPath; using System.Net; public partial class Auctions_Default : CommunityServer.Components.CSPage { void Page_Load(object sender, EventArgs e) { RSSFeeds(); } void RSSFeeds() { string[] aFeeds = { // Display the following feeds in the calendar "http://nixonauctions.com/Feeds", "http://michaelauction.com/Feeds", "http://success-auctions.com/Feeds" }; DataSet dta = new DataSet(); for (int i = 0; i < aFeeds.Length; i++) {
// Loop through and add the feeds HttpWebRequest feed = HttpWebRequest.Create(aFeeds[i]) as HttpWebRequest; DataSet ds = new DataSet(); ds.ReadXml(feed.GetResponse().GetResponseStream()); if (dta.Tables.Count == 0) { dta.Tables.Add(ds.Tables[2].Copy()); } else { dta.Tables[0].Merge(ds.Tables[2].Copy()); } ds.Clear(); } dcAuctions.DataSource = dta.Tables[0]; dcAuctions.DataBind(); dcAuctions.DayField = "pubDate"; } }
You could use this to aggregate and display select blogs, news columns, pictures, videos, etc. You may have to tweak the DataSet to adjust for different feed types, change some formatting, add some error handling but, if it"s got an RSS feed, you can calenderize it.
I set out to change that. Companies would no longer be able to select me from a generic lineup of candidates. Instead, I would select companies. Companies that I respected, companies that shared my passion for software. Armed with thirty years of hindsight, I would no longer let random, chance opportunities determine my career path. I will choose where I want to work.
If you love software as much as I do, you deserve to work at a company where people come to work not to punch a clock, but because they love software, too. You deserve to work at a company where software engineering is respected. You deserve to work at a company where peers meet to enjoy building software together.*
Coding Horror: Remember, This Stuff Is Supposed To Be Fun
That"s exactly why I chose to work at innoveo solutions.
Tonight I reached a new milestone on my current development for my portal Tech Head Brothers.
You might know, or guessed, from one of my last post; "Tech Head Brothers Silverlight Streaming framework" that I am working on adding Silverlight Streaming to Tech Head Brothers. I first released a little framework to ease the development against the REST API of Silverlight Streaming. Now I went further on with a first vertical slice of the whole solution.
The solution is composed of four parts:
After quite some discussions with Mathieu about the best posting user experience for the different authors we finally decided that using Live Writer was the best solution! And now that I have the first vertical slice I am really happy about the choice we made, because it makes the solution easy for the authors but also for us implementing the solution.
The client application customize Live Writer with a SmartContentSource plugin letting the author upload it"s video to Silverlight Streaming but also posting all information to Tech Head Brothers as a blog post.
The cool point here is that during the development of innoveo solutions website; my new company, I wrote a generic blog engine that basically let you define a blog just by adding an httphandler and implementing a Converter class:
Definition of a new blog, that will be used in the httpHandlers part of the web.config
public class VideoBlog : GenericBlog<Video> { public VideoBlog() : base(new VideoBlogAssembler()) { } }
Definition of the converter class, converting an business entity to/from a Post
public class VideoBlogAssembler : IBlogAssembler<Video> {
/// <summary> /// Converts the specified video. /// </summary> /// <param name="video">The video.</param> /// <returns></returns> public Post Convert(Video video) { Post post = new Post(); post.dateCreated = video.PublishDate; post.description = video.Description;
...
The admin part was quick to develop just extending the page I already had for articles publication.
And finally Mathieu did a great job on the XAML Silverlight Player and all the javascript part that I juste needed to integrate.
So now you know it, yeah we are adding Video to Tech Head Brothers and I hope really soon.
I’ve received a great number of emails in response to my “Scoble Gap” post.
The first that has prompted me to white included this question.
“Can you separate M$ lip service from fact for us? That has to be the toughest part of your future.”
By this I assume the poster is refereeing to Microsoft MARKETING.
I’m not a fan of most marketing, ours or anyone else’s. But, it’s a necessary part of business. Marketing’s role is to advise the consuming audience of the potential benefits and values of the product they represent or “market”.
As geeks, we often see most marketing “collateral” as too many words containing little or no information.
It’s a hard balance, at Microsoft we have marketing folks that are really non-technical, and then we have folks that work in marketing capacity that are very technically competent (Brian Goldfarb).
It’s not what our marketing says that worries me. It’s when our people, especially our executive management are fully buying our own “stuff”.
MS Haters probably see this as arrogance. I see it more like a parent as he/she looks at their own children and have to work to set aside personal bias and proactively look for “areas that could use improvement”.
I have “that type of discussion” frequently inside Microsoft, now I’m just committing to make most of those opinions public.
So, call us out on what you think is “lip service” by emailing me though my blog – I won’t shy away from topics. J
Site List:
>>Xbox Live_s Major Nelson
>>Xbox 360 & SharePoint 2007 Weblog
>>Carsten Keutmann_s Blog
>>Mohamed Zaki_s Blog [Sharepoint MVP]
>>The Mit_s Blog
>>Mart Muller_s Sharepoint Weblog
>>Microsoft SharePoint Products and Technologies Team Blog
>>SharePoint Solutions Blog
>>4GuysFromRolla.com Headlines
>>ASP.NET Blogs
>>SharePoint Blogs
>>SharePoint Blogs
>>Joel on Software
>>ADO Guy_s Rants and Raves
>>Microsoft Live Labs
>>GadgetNews
>>Windows Vista Team Blog
>>VoIP & Gadgets Blog
>>schrankmonster blog
>>Via Virtual Earth Blog
>>Feed
>>MSDN Blogs
>>Mashable!
Links:
Jack's Readings
Month Archives:
Oct 2007
Sep 2007
Top Tags:
social software social networking .NET mashable Sharepoint ASP.NET Web 2.0 Web2.0 Startups Community News Search Marketplace General Software Development AJAX Windows Vista Visual Studio Microsoft myspace Silverlight People Powered! YouTube Vista MOSS Featured News C# Events MOSS 2007 Google WPF Office 2007 Web Community Security General Personal Xbox 360 facebook Tools development SharePoint 2007 Fun Atlas Architecture ASP.NET AJAX myspace codes TheLongTail IIS SQL Server Developers Revenue Sharing Video Pictures WCF Mobile 2.0 Announcements Orcas MIX07 Arcade Team System JavaScript News
@2007 All rights Reserved |