Archives
-
Outlook 2010 Beta - Still not implemented
Previously in the saga: Outlook 2010 Beta - "Not Implemented" on Send/Receive.
It would appear that problems with Outlook complaining that something is "Not Implemented" are more …
-
DataTable Key/Value columns to Dictionary
There are undoubtedly more elegant ways to do this using LINQ, but to quickly and easily take the key (int) and value (string) columns from a DataTable and turn them into a Dictionary<int, string>, …
-
Outlook 2010 Beta - "Not Implemented" on Send/Receive
I yesterday installed the Office 2010 beta and almost immediately came across a fairly serious "bug". It's debatable whether the bug was caused by Microsoft (i.e. a fault on the part of Office) or by …
-
MySql ServerName.Log file size
A quick and dirty hack (written in C#) to solve the issue of MySql query log files getting huuuge:
System.ServiceProcess.ServiceController sc = new ServiceController("mysql", "servername");sc.Stop(); …
-
extJs: Combobox .getValue oddity - 2 (The "Solution")
Previously: extJs: Combobox .getValue oddity
Here's a quick-hacky solution (a better one would be to ensure your combobox's are selection-only):
Ext.override(Ext.form.ComboBox, { getValue: …
-
extJs: Combobox .getValue oddity
At least in extJs version 2.2.1 (the version baked into Coolite v0.8), the getValue function on the Ext.form.ComboBox appears to be thus:
function(){ if (this.valueField&&this.forceSelection) { …
-
A review of "Review: CryptoLicensing for .NET"
The review of CryptoLicensing for .NET that Roy Osherove posted recently was very well written and covered a topic that I've long held a mild level of curiosity around. That topic being protecting …
-
MySql - Running a complex script using the .net Connector
[The solution was discovered via this entry in the mysql.com forums]
If your MySql script contains code like
"/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;"
You'll need to add …
-
A string of character 'x' the same length as string 'y'
... is quite simple in .net, as I found out! string title = "My line of text that I'm writing to the console underlined with equals signs"; Console.WriteLine(title); …
-
Sorting the results of DirectoryInfo.GetFiles
Say you wanted toget a list of all the SLN (Visual Studio Solution) files in a given directory and all child directories, sorted alphabetically, you could use something similar to this:
public …
-
A number that equals twice the sum of its decimal digits
Riffing on "dix-huit ans aujoud'hui = 18 pounds!" from Frankarr, an australian blogger.
In the entry he mentions that "One fact about 18 which I really love is that 18, aside from 0, is the only …
-
ASP.NET Expression Builders - Part 3 - Wiring it up in web.config
The final piece of the puzzle to get an Expression Builder working is the entries that are required in the web.config file. Assuming that your expression builder class is in the App_Code directory, …
-
ASP.NET Expression Builders - Part 2 - Using them for Localisation
An expression builder is invoked by ASP.net when it transforms the ASP.net server control markup into C# code ready to be compiled and then rendered out, allowing code to be invoked to set properties …
-
ASP.NET Expression Builders - Part 1
Some linkage first:
Use ExpressionBuilder To Avoid "Server tags cannot contain <% ... %> constructs"
The CodeExpressionBuilder
skmExpressionBuilders - A Suite of Custom Expression Builder …
-
Finding a row in a DataTable
If you have a System.Data.DataTable that contains the columns {ItemId, ItemName, ItemQuantity} and wanted to find the record for a given ItemId, you could always use the followind code:
int …
-
An attempt was made to load a program with an incorrect format
Could not load file or assembly 'NameOfAssemblyGoesHere' or one of its dependencies. An attempt was made to load a program with an incorrect format.
This message being spewed- …
-
Exclude SCC / VSSSCC files from Web Setup Projects
The structure of a Web Setup Project (.vdproj) file is just plain strange as it's "kinda" like XML but with curly braces ( { and } ) and quotes instead of < and > symbols.Go figure.
If you have a …
-
Formatting a number to be zero-padded
int i = 3;string padded = string.Format("{0:5D", i);
Gives a value of "00003" as the string called "padded" - that simple.