Archive for the 'Programming' Category
Passing URL parameters on the query string is very standard, and yet Javascript doesn’t give an easy way to access them, leaving each of us to have to re-invent the wheel ourselves. This puts us each on a google search to try to find a good function. I found one at: http://www.netlobo.com/url_query_string_javascript.html Kudo’s to “lobo235″ [...]
One of the big problems I faced in .Net 1.1 web applications was capturing the enter key so that the correct asp:button would be “clicked.” To solve this problem, ASP.Net 2.0 lets you specify this on the html form element with the defaultfocus and defaultbutton attributes. This is really slick and works like a charm. [...]
Most programming languages have built in libraries for generating random numbers from a uniform distribution. If you need to convert this to a normal or Gaussian distribution, some sort of transformation must be made. I found a good page that talks about this process and gives some example code in how to convert a uniform [...]
In a project I’m working on, and using LINQ, there have come a few times when I have needed to create my own SQL and send a query to the database. This has typically happened when I’m not doing queries that aren’t very straight forward, but I still want to accomplish the task with only [...]
Sometimes you have a library running outside of your traditional debug mode, but would like to call into it with a debugger. I specifically ran into this with a custom installer dll called by a custom action in my MSI. The following code will allow the process itself to request debugging. Then you can specify [...]
LINQ "gotchas"
I am using VS 2008 and LINQ (specifically LINQ to SQL) for a project at work right now. As I jump into this, I am going to document some of the pros, cons, and “gotchas” that I come across. Any articles in this series will have the label “LINQ” . Here is my first list [...]
For a project at work we were building deployment projects for some fairly large web applications. 300-600 MB after compression on disk. When the deployment project would build, it would fail with the following result: “ERROR: Could not find file ‘xxxxx.xxx ‘Not enough storage is available to complete this operation.’” After googling around, I found [...]