Binary Representation of Decimal Values#
More decimal issues, but unrelated to the SQL stuff. The problem being that numbers like 1/10 can be easily displayed in base 10 as 0.1. But, in base 10 we have problems with numbers like 1/3, .3333333333. Well, in binary, they have problems with some of our decimal numbers that you wouldn't expect. e.g. 0.4 - 0.1 = 0.30000000000000000000004 while 1.4-1.1 = 0.29999999999999999999998.

The problem here is with rounding. I wrote a quick JS function to round these numbers to a significant number of digits.
Categories:
Thursday, September 29, 2005 6:50:28 AM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

SQL Server's Stupid "Decimal" DataType#

Ok so, on a recent project, for some reason, I set up a few fields, and the corrosponding SP parameters as "decimal" datatypes. What a mistake.

After lots of rounding errors, which were partly ignored because the revised "specs" called for these figures to be integers (later changed to decimals), I found out that a Decimal datatype has no decimal places, unless you specifically declare it.

The reason for this is that a "decimal" is really just another name for a "numeric". So I guess I can understand that part... but how dumb is it that a decimal, by default, has no decimal places.

I went back and changed everything to float.

Use decimal(x,x) instead of float.  See here for the reason why.

Categories:  |  |  | 
Tuesday, September 27, 2005 8:42:13 AM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

The destruction of my ugly bar#
When my wife and I first moved into our house, the first thing we wanted to do was get rid of this ugly, and seemingly useless bar in our basement.

To be honest I have no idea what anyone would have done with this thing, but at some point someone spent a lot of time to install this thing.

The day finally came when I decided it was time to take action (mostly because I have to sell my house very quickly and this thing is ugly).

I wish I had some "before" pictures, but I didn't think about that when I started.


Some of the junk that was removed, awaiting disposal.



The newly freed space. We are going to make this where we put our TV and stuff.



This was the most interesting part for me. I had to cut some pipes running to the sink in the bar and sweat on a cap. I had never done this before so it wasn't that easy, and it was made even harder by the fact that I had about 18" of space to work with in this area behind the bar. But, it's finally done.
Categories:
Friday, September 23, 2005 7:20:18 AM (Central Standard Time, UTC-06:00) #    Comments [1]  | 

 

More on AssemblyVersion and AssemblyFileVersion#
I just came across this post by Carlos J. Quintero, a .net MVP.

He explains basically what I have been encountering in dealing with versioning of assemblies.

He even points out the bug I found with auto incrementing the AssemblyFileVersion number.
Carlos J. Quintero [.NET MVP] Jun 23, 3:34 am

Newsgroups: microsoft.public.dotnet.framework
From: "Carlos J. Quintero [.NET MVP]" <carl...@NOSPAMsogecable.com> - Find messages by this author
Date: Thu, 23 Jun 2005 10:34:05 +0200
Local: Thurs, Jun 23 2005 3:34 am
Subject: Re: AssemblyVersion numbers and recompiling code
Reply to Author | Forward | Print | Individual Message | Show original | Report Abuse

Hi Joe,


There are 2 versions that you need to take care of:


1) The version of the file: this is the version of "classic" Win32
applications or DLLs, that is, the one shown using the Properties dialog of
Windows Explorer.


It is set with the AssemblyFileVersion attribute in AssemblyInfo.vb file:


<Assembly: AssemblyFileVersion("1.0.2.4")­>


Notice that this attribute is not written by default when the file is
created so you need to add it by hand.


This is the version that should be autoincremented but, alas, using "1.0.*"
does not autoincrement it in each build. I would say this is a bug.


2) The version of the assembly: this is the version of .NET assemblies,
which is different than the file version. That is, this is the version shown
in the Property dialog of the GAC in the first tab (the second tab shows the
file version). For example, in Net Framework 1.1, System.Windows.Forms has a
file version 1.1.4322.573 and an assembly version 1.0.5000.0


It is set with the AssemblyVersion attribute in AssemblyInfo.vb file:


<Assembly: AssemblyVersion("1.0.0.0")>



Notice that this attribute is written by default when the file is created so
you don´t need to add it by hand.


This is the version that can be autoincremented using "1.0.*" but generally
you don´t want to do this because you want to keep the same assembly version
in each build until you break the backwards compatibility. I would say that
this autoincrement feature is another bug.


So:


- Change always the AssemblyFileVersion on each build.


- Change the AssemblyVersion only if you are breaking the backwards
compatibility. Do not change it for bug fixes or other minor INTERNAL
changes which won´t break clients.


- Clients can be configured through a config file to run against an exact
dll a.b.c.d or with any a.b.* build number (provided that major and minor
digits don´t change). See the .NET Framework docs about this.


--
Best regards,


Carlos J. Quintero
Categories:
Monday, September 19, 2005 10:14:55 AM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

The LINQ Project#
The LINQ Project is a codename for a set of extensions to the .NET Framework that encompass language-integrated query, set, and transform operations. It extends C# and Visual Basic with native language syntax for queries and provides class libraries to take advantage of these capabilities.
Categories:
Monday, September 19, 2005 8:45:31 AM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

AJAX in ASP.NET 2.0, code name "Atlas"#
I have already been rolling my own AJAX based controls (and they are sweet, I have to say I am very proud of how OO I was able to make them on the client side). Microsoft has a set of extensions that are supposed to let you do this stuff with asp.net called Atlas. They have a website set up to talk about some of the specifics.
Categories:
Monday, September 19, 2005 8:30:28 AM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

FSBO#
I am still working through all the FSBO crap.

It seems that http://www.buyowner.com/ doesn't put your site in any MLS, so it doesn't show up on ChicagoTribune.com or Realtor.com.
http://www.listmefree.com looks like they DO put you in the MLS, but you have to pay a buyers commission.
This site, which I think is just an alias of nuwaymls.com seems to suggest that they get your house in the MLS and Realtor.com but you don't work with realtors to do the selling... but you use a realtor to list it?
Categories:
Sunday, September 18, 2005 10:58:32 PM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

Device Mounts For Cars#
My brother showed me http://www.proclipusa.com/ today. It's pretty cool. They have a bunch of different clips that fit all kinds of cars and devices.
Categories:
Sunday, September 18, 2005 10:21:58 PM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

Code Access Security#
In a project I am working on, one of the requirements was that the application be allowed to browse its own pages (e.g. programatically open up a web request and browse the html pages that are served up by the site).

Anyway, this permission is not allowed on the hosting environment they decided to use. This page talks about the permissions available in ASP.NET 2.0, and the different levels of security you can set on applications.
Categories:
Sunday, September 18, 2005 7:41:17 PM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

Resetting a Cisco Password 2#
Here is the documentation from Cisco, but again I don't see anything about if it resets everything
Categories:
Friday, September 16, 2005 9:29:58 AM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

Resetting a Cisco Password#
This article is supposed to show you how to reset the password from the terminal on a cisco router. Not sure if it will work or if it will erase the config. I will need to find out.
Categories:
Friday, September 16, 2005 9:29:26 AM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

DLL Hell a possible solution (repost)#
After making some newsgroup postings and researching a bit. I found out some info that might be a contributing factor to our problems with assemblies getting referenced correctly. In our assemblyinfo file we are auto incrementing the AssemblyVersion . From my reading, this attribute is actually meant to BREAK combatibility. What we need to be using is the AssemblyFileVersion. This can be incremented w/o breaking compatibility and still help us figure out what DLL we are dealing with (which version). This blog has an entry about it.

Note: I had to repost because I accidently used some tags in my article that don't show up.
Categories:
Thursday, September 15, 2005 9:29:08 AM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

DLL Hell, a possible solution#
After making some newsgroup postings and researching a bit. I found out some info that might be a contributing factor to our problems with assemblies getting referenced correctly.

In our assemblyinfo file we are auto incrementing the . From my reading, this attribute is actually meant to BREAK combatibility. What we need to be using is the This can be incremented w/o breaking compatibility and still help us figure out what DLL we are dealing with (which version).

This blog has an entry about it.
Categories:
Thursday, September 15, 2005 8:34:56 AM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

How Assembiles Are Located#
This article on MSDN details how assemblies are located by the Runtime.
Categories:
Tuesday, September 13, 2005 9:26:29 AM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

Cool Javascript Effects#
Not sure if I have linked to http://script.aculo.us/ before, but they have some cool javascript effects on there. To top it off, they are free.
Categories:
Tuesday, September 13, 2005 8:18:06 AM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

.NET DLL Hell#
.NET was supposed to resolve the problem of DLL Hell.

Well that is exactly where I am right now: DLL Hell.

I have wasted so much time on stupid versioning issues and other problems that seem to have no cause whatso ever.

Right now I try to build and I get the error:
Cannot copy assembly 'ASDF.Web.Controls.DateTimeControls' to file 'C:\Data\WalshVSSRoot\ASDF.Web.Users\bin\Walshgroup.Web.Controls.DateTimeControls.dll'. The process cannot access the file because it is being used by another process.

Thats nice. No one is using the fricking file, and I haven't had this problem during my last ... oh I don't know... say ...10,000 builds, but now it is becoming an issue. Great.

My other new friend is this error:
The located assembly's manifest definition with name 'ASDF.Web.Controls.LookupControl' does not match the assembly reference.
Thats nice... manually updating the reference, removing it and readding it, rebuilding, manually copying the DLLs to the bin etc don't help. This is a POS. WTF.
Categories:
Monday, September 12, 2005 2:41:04 PM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

Custom Controls and ASP.NET Validation (Client Side) (MORE)#
It turns out that when I said:
It turns out that when I said: Turns out it is as simple as adding [ValidationPropertyAttribute("­Text")] to your class definition for the custom control. That's easy! it really wasn't that easy, at least to get client side support for asp.net validators to work. After a lot of research, and a bunch of looking through the page output I figured out what must be done. If you have a custom server control and it is named "MyDateTime1", then the HTML element that you want to check in your client side validation must also be named "MyDateTime1". In my control, I would output a bunch of different elemnts, using things like ClientID + "_textbox" and ClientID + "_Icon" etc... All I had to do was make sure the textbox (which is what I wanted to run the client side validation against) was named simply this.ClientID and presto!
It really isn't that easy.

I think this worked before because I was created HTML elements, and not ASP.NET Webcontrols. I am trying to basically do the same thing, and let me tell you, it isn't working. I am getting an error saying that there are more than 1 control w/ the same name. The problem (I believe) is that container control is registered w/ asp.net, and when I dynamically add an asp.net textbox with the same name as the parent control, it flips out. With my other control I was just adding an HTML textbox.
Categories:
Friday, September 09, 2005 12:16:28 PM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

Mortgages and Stuff#
Just to keep a list of what I am working through here:

I am part way done with the loan process at this place, and they seem to have the lowest price so far (I need to get tax info from Kathleen to complete it). They were 5.375 + 660 closing.
Here is another place I was looking over, those rates are from mtgcapital.com.
I haven't yet gone through this site.
Here is yahoo's list of common closing costs.
I haven't called these guys.
Categories:
Friday, September 09, 2005 9:06:38 AM (Central Standard Time, UTC-06:00) #    Comments [1]  | 

 

Dynamically putting a DIV over Dropdown objects#
Pretty much everyone has the problem of getting a something to show on top of a dropdown at one time or another.

I just found this solution and it appears to work for me. I made some modifications to their ideas to get it to work better for me, but the basic jist is that you dynamically create an IFRAME element and position it w/ a zindex just below the div's zindex, but it will hide the contents below the iframe because it is considered a "window" object
Categories:
Wednesday, September 07, 2005 1:58:11 PM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

"Hidden" Members#
In VB.Net it has bugged me that some members simply don't show up in intellisense. For example, in asp.net pages, Me.RegisterClientScriptBlock will not show in in intellisense. Once you have typed out the full name, THEN it will show you the required parameters, but still I didn't understand why it did this in VB, and yet C# has no problem.

So I finally did some digging and found that VB HIDES what they call "Advanced" members. I guess they are protecting us dumb VB programmers from getting overwhelmed by extra options and methods. Idiots!

In VS.Net go to Tools > Options > Text Editor > Basic > General and then uncheck Hide advanced members.
Categories:
Tuesday, September 06, 2005 10:01:55 AM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

Modifying HTML Before Sending To Client - 2#
After further review, it looks like I probably can't use the PreSendRequestContent event w/ an http module to do what I want. Using a Filter appears to be the way to go.

However, after MORE thought, I think I probabaly will implement what I want from within the specific application. I think there would be too much processing overhead to filter out stuff on every page of every request to the site, just for a minor amount of editing.

Here is an article on someone modifying their output into XHTML, and here is the discussion on it.
Categories:
Monday, September 05, 2005 7:09:19 PM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

Modifying HTML Before Sending To Client#
I am trying to figure a way to modify the output HTML from all pages on a site, while trying to avoid writing code into a base class.This page show the use of an HttpResponse Filter. Their example wires up the filter in the base class, but I am hopeful that I can do the same with an HttpModule, such as this page where they use the PreSendRequestContent event.
Categories:
Monday, September 05, 2005 6:17:57 PM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

Garage#
We are looking at getting a new house, but some of the ones we are looking at don't have a 2 car garage. I am wondering about how much it would cost us to erect one. This website has some "estimates" for home additions and building.

It looks like they think it should cost 12,000 (and up). But for some reason that sounds pretty low to me. Apparently these guys are doing a lot of garages in the web suburbs, so I am going to call them to see if I can get a "real" figure. I'll also call these guys.
Categories:
Monday, September 05, 2005 5:22:02 PM (Central Standard Time, UTC-06:00) #    Comments [0]  | 

 

All content © 2008, Christopher May, Inc
Open Job Positions
On this page
Google Ads
This site
Calendar
<August 2008>
SunMonTueWedThuFriSat
272829303112
3456789
10111213141516
17181920212223
24252627282930
31123456
Archives