Archive for 'Random' Category

web3 is undefined even when metamask is installed

By admin - Last updated: Thursday, March 15, 2018

If you have metamask installed, the web3 object should be populated. The invalid html doctype may cause the problem. Double check to see if you have <!DOCTYPE html> on top of your html document. 🙂  

Ether Wallet

By admin - Last updated: Sunday, December 3, 2017

0x0A25196aBA41d5e026E552C6b6885c625010c6A2

DOS delete all svn related folders or files

By admin - Last updated: Tuesday, August 21, 2012

Run the command on the dir which contains the versioned files or folders. for /d /r . %d in (.svn) do @if exist “%d” rd /s/q “%d”

New Zealand Graduate Job Ready Programme

By admin - Last updated: Thursday, May 6, 2010

I am participated in taking the sessions to show cases to graduates for .NET development. Check out Graduate Job Ready Programme Offered Here “The ‘Job-Ready’ Programme is a practical course specifically designed for people wanting to get their first job in Software Development.  It is created and presented by experienced software developers and IT professionals, who […]

Random scripts

By admin - Last updated: Sunday, March 7, 2010

SQL transaction try catch template BEGIN TRY BEGIN TRAN — sql goes here COMMIT END TRY BEGIN CATCH SELECT ERROR_NUMBER() AS ErrorNumber ,ERROR_SEVERITY() AS ErrorSeverity ,ERROR_STATE() AS ErrorState ,ERROR_PROCEDURE() AS ErrorProcedure ,ERROR_LINE() AS ErrorLine ,ERROR_MESSAGE() AS ErrorMessage ROLLBACK END CATCH Very nice blog around WCF security http://www.leastprivilege.com Search object name within SQL database SELECT name […]

A simplest/dumbest CSharp IDE

By admin - Last updated: Sunday, November 29, 2009

The tiny WPF app (14k) has a textbox allows the input of the C# code, it compiles the code and execute the code after press F5 key. Here is what it looks like. No surprise. The main part which compiles the code at runtime is using CSharpCodeProvider from Microsoft.CSharp namespace. static CompilerResults Build(string code, IEnumerable<string> […]

VS 2008 Project: Group/nest source code files

By admin - Last updated: Thursday, November 26, 2009

Like windows form project, the design code and source code are grouped together for the ease of code management. You can group any related files in to one expendable tree view. Before grouping After grouping That’s pretty handy aye! Unfortunately, there is no UI to do this. The only way I’ve found is to modify […]

Quick Programming References

By admin - Last updated: Friday, October 30, 2009

Ajax, C++, Java, Python, PHP, Perl, ASP, Unix, Ruby, Google, HTML, CSS, XML etc Actionscript Quick reference/Cheatsheet for ActionScript 2.0 Ajax What’s Ajax? Cheat Sheet — PDF Prototype Dissected — Cheat Sheet PNG scriptaculous Combination Effects — Cheat Sheet — PDF Apache Apache Cheat Sheet htaccess Cheatsheet mod_rewrite Cheat Sheet — PNG mod_rewrite Cheat Sheet […]

Cruisecontrol.net Could not load file or assembly NetReflector

By admin - Last updated: Tuesday, August 11, 2009

You may encounter this problem when adding in a plugin say ccnet.SvnRevisionLabeller.plugin.dll to ccnet. The cause is that they used different version of NetReflector.dll The 2 min solution I found is to build your own ccnet.SvnRevisionLabeller.plugin.dll by referencing the existing NetReflector.dll used by CruiseControl.NET Step 1, Download the source from svn endpoint http://svnrevisionlabeller.googlecode.com/svn/trunk Step 2, […]

IE8 is being detected as IE 6

By admin - Last updated: Wednesday, May 13, 2009

I logged in facebook with newly installed IE8, and on top of the page, it displays “Please Read This”, my first thought was that facebook is going to announce something important like they did for new theme a while ago. Interestingly, it asks me to upgrade to IE7 since IE8 was recognized as IE6. Check […]

April 1st @ StackOverflow

By admin - Last updated: Wednesday, April 1, 2009

01/April/2009, stackoverflow becomes the kids’ palace!

Reduce computer noise

By admin - Last updated: Thursday, February 19, 2009

If you think the PC gets a bit louder than before, mostly likely your CPU is over heating because the cooler system is not working properly. I had experiences of reducing the noise with two of my PCs. The solution I did for the older PC was two years ago, the noise was due to […]