Free Template: Two-Tenths

Two-Tenths Template Screenshot

As always, you can do whatever you want with it. A mention and a link isn't necessary but is very much appreciated. :-)

View the template

Download the template files

Commenting Out Server Controls in ASP .NET

This is something I seem to be doing an awful as of late. I start out with some control (say a GridView), then switch to some other control (say a Repeater), but I don't want to delete the GridView control until I get the Repeater control working.

You might have tried commenting out the control the HTML way — i.e., <!--...--> — and you probably found out that ASP .NET engine still parses it. Until recently, I was dealing with this the hard way: cutting & pasting the control into Notepad.

No longer.

Enter Server Comments

Namely:

<%--

 <asp:GridView ID="ProductsGridView" runat="server" DataSource="ProductsDataSource">
 </asp:GridView>

--%>

ASP .NET will ignore everything within a server comment block.

One Penny

One Penny Template Screenshot

Feel free to do whatever you want with it as long as it doesn't involve making money off of it. As always, a mention and a link though not required is appreciated very much.

A Wordpress theme based on this template is forthcoming. So stay tuned.

[ View the template ]

[ Download the template files ]

Free Template: Natatorium

Natatorium Template Screenshot

Started out as a tutorial to make tables less boring via applying various formattings and ended up as a template instead. Enjoy. :-D

Look at the template

Download the files

How To Show Some Rows Differently in a GridView

Suppose you're showing a list of customers, and you want to highlight any customer who'd been with you since before 1920. Maybe you also want the JoinedOn field to show the number of months for customers who've been with you for less than a year. It's fairly easy.######Add OnRowDataBound Handler to GridView

The easiest place to change the data is just after the data gets bound to the row. So:


<asp:GridView runat="server" ID="CustomerGrid" OnRowDataBound="CustomerGrid_OnRowDataBound">
</asp:GridView>
Make the changes in CustomerGrid_OnRowDataBound

protected void CustomerGrid_OnRowDataBound(object sender, GridViewRowEventArgs e)
{
 GridViewRow row = e.Row;

 // Make sure we aren't in header/footer rows
 if (row.DataItem == null)
 {
  return;
 }

 Customer customer = row.DataItem as  Customer;

 if (/* Do your conditionals here*/)
 {
  // Change Row formatting here OR
  // Add new cells 
  // Or create an entirely different cells
 }
} 

How do you format a date variable in a GridView?

<asp:BoundField DataField="CreatedOn" DataFormatString="{0:M/dd/yyyy}" HtmlEncode="false" />
######Other Resources:

10 (+ 2) Kick-Ass Wallpapers

From Deviantart.

1. Throb by pixelcatalyst

Screenshot of Throb

Source

2. Falling Rains 2 by preppy

Falling Rains 2

Source

3. Liquid Flower WP by gavinwm

Liquid Flower WP

Source

4. Dreamcatcher by viperv6

Dreamcatcher

Source

5. Nemesis Ovaela by syragon

Nemesis Ovaela

Source

6. Dysphoria by zilla774

Dysphoria

Source

7. Ghostic Widowmaker by zygrael

Ghostic Widowmaker

Source

8. Sylon by viperv6

Sylon

Source

9. Sweet Sugar by sypheck

Sweet Sugar

Source

10. Transfer Section 47 by niteangel

Transfer Section 47

Source

Bonus: convergingDivides by riftfusion

Converging Divides

Source

Bonus 2: Parallel Dimensions by jedeye459

Parallel Dimensions

Source

A Bit More Wordpress

Wordpress Templated Screenshot

Wordpress Templated is, as you might have guessed from the screenshot, a little utility written to make your life better by making theme-creation easier.

For example, if you are anything like me, you can never remember the doctype specification for — wait for it — any doctype. Well, now you don't have to: simply type in "{Doctype type="Xhtml 1.0 Strict"}", click a button, and sit back and watch as you get the doctype url back. On second thought, don't sit back, because you'll surely get frustrated at having to come right back to an upright position. ;-)

Go play with Wordpress Templated

Let me know what you think

1 of 2 pages  1 2 >

On the Side