Category Archives: Snippets

quick code tips for single elements, attributes, or details

Excel – Find widest value in range of cells

Here is an excel tip for finding the maximum width/length of values in a range of cells. It is useful when converting spreadsheets to databases where you need to define the data attributes. Type the following including braces into a … Continue reading

Posted in Snippets | Comments Off on Excel – Find widest value in range of cells

Coldfusion bug – dialog box redirects on ok

I had an interesting problem to figure out today. On one of my forms I had a Help icon which the user could click and it would display a dialog box with help. Sometimes the box would just close, other … Continue reading

Posted in Coldfusion, Problems & Fixes, Snippets | Comments Off on Coldfusion bug – dialog box redirects on ok

CF linebreaks in excel same cell

By default when you add the BR tag inline Excel will interpret that as you want a new cell. We sometimes merely want a line break. When outputing to excel use this syntax in your code to keep linebreaks in … Continue reading

Posted in Coldfusion, Snippets | Tagged | Comments Off on CF linebreaks in excel same cell

SQL Server – Reset Identity Column

How to reset the identity counter in SQL SERVER DBCC CHECKIDENT(‘tablename’, RESEED, 0) The zero can be any positive value. I often use the year as numbering system like 2012000001

Posted in Snippets, SQL | Comments Off on SQL Server – Reset Identity Column

Javascript – checkboxes are checked?

How to Evaluate if Check Boxes are checked when submitting a form. Throws an error if none are checked. Continue reading

Posted in Javascript, Problems & Fixes, Snippets | Comments Off on Javascript – checkboxes are checked?