November 2005 - Posts

collapsible code sections (#region, #endregion)
Published 11-30-2005 12:28 PM | jokiz
visual studio .net comes with the #region and #endregion directives to be able to collapse code sections using the IDE. by default, the generated code (i.e. InitializeComponent method block) which is used by winform and webform designer to recreate the...
Filed under: , ,
Combobox SelectedIndexChanged vs SelectionChangeCommitted
Published 11-23-2005 11:05 PM | jokiz
In ASPNET we only have SelectedIndexChanged ( DropDownList ), in Windows Forms we have both, but which one to use? My first .NET project is a Windows Application which uses databinding a lot and we were using SelectedIndexChanged of Combobox back then...
Two MS exam vouchers for free
Published 11-23-2005 11:04 PM | jokiz
i've been using a lot of bitwise operation in my stored procedures lately as seen in my previous blog post . luckily, i was able to use it to answer the previous trivia question from PHISSUG where i was able to receive good feedback. now I have two free...
Filed under:
ANSI_NULLS OFF inconsistencies
Published 11-20-2005 5:09 PM | jokiz
Basically I have this nullable column which I wanted to filter my resultset from. Let's take the authors table of the pubs database as an example. SELECT * FROM authors where au_fname = ISNULL(@firstname, au_fname) Seeing the query this way, I thought...
Filed under: ,
Naming Guidelines
Published 11-10-2005 12:16 AM | jokiz
In response to dehranph's comment on my previous post ( http://community.devpinoy.org/blogs/joeycalisay/archive/2005/11/08/401.aspx ), it reminded me of the naming guidelines in .NET. His comment was about the DeleteCustomer method which has a Customer...
Filed under: ,
OOP-Encapsulation issues
Published 11-08-2005 11:14 PM | jokiz
As I was refactoring some of our codes, what struck me was the idea of object oriented programming particularly encapsulation. For example, we have this Customer object which is distinct with its CustomerID property. We needed to have versioning for the...
Filed under: , ,
Datatype Precedence in SQL Server
Published 11-08-2005 10:37 PM | jokiz
Wasn't really familiar with this feature of SQL Server until today. I have a 4-character field (BidTypeID) in SQL server which actually contains integers (pardon the design issues here people) which i have configured as flaggable enumerations in C#. My...
Filed under: ,