Posts

Network Monitor MSI / Setup give Error Opening log file

When you try to install using Microsoft MSI, you bump into the following message “Error Opening Installation log file. Verify that the specified log file location exists and is writable” Workaround, extract the .exe file by using the following command below NM33_x86.exe /c /t:c:\tools\networkmonitor the /t switch is used to tell installer where to extract the file. Then try to run netmon.msi to install network monitor. I tried it with Network Monitor 3.3 and it works (Netmon.msi and Microsoft_Parsers.msi)

Streaming Algorithm

This is going to be an ongoing update to some interesting streaming algorithm that i found over the web. If anyone have any input, please let me know. -- Haven't really work on it yet --

Recommendation algorithm

This is going to be an ongoing update to some interesting recommendation algorithm that i found over the web. If anyone have any input, please let me know. Contextual-Bandit algorithm - Li Long, Wei Chu, J.Langford, R.Schapire -Adapting machine learning approach for recommending advertisement, news and other articles to users. Nearest Neighbour Algorithm - To be updated :) Resources : Nearest Neighbour Algorithm ( This give a really easy to understand overview of the algorithm - far better than alot of the lecture notes given by professors ) http://people.revoledu.com/kardi/tutorial/KNN/index.html

Case sensitive in JQuery class selectors

When you're using jquery's class selectors for example, $('a.lookupScript'), it will work in Mozilla but not on IE. So you gotta make sure that you got the case right. :)

Determining IIS version your server is running on.

I got this from Microsoft Support site... :) Version Obtained from Operating System 1.0 Included with Windows NT 3.51 SP 3 (or as a self-contained download). Windows NT Server 3.51 2.0 Included with Windows NT Server 4.0. Windows NT Server 4.0 3.0 Included with Windows NT Server 4.0 Service Pack 3 (Internet Information Server 2.0 is automatically upgraded to Internet Information Server 3.0 during the install of SP3). Windows NT Server 4.0 4.0 Self-contained download from www.microsoft.com or the Windows NT Option Pack compact disc. Windows NT Server 4.0 SP3 and Microsoft Internet Explorer 4.01 5.0 Built-in component of Windows 2000. Windows 2000 5.1 Built-in component of Windows XP Professional. Windows XP Professional 6.0 Built-in component of Windows Server 2003. WIndows Server 2003 7.0 Built-in component of Windows Vista and Windows Server 2008. Windows Vista and WIndows Server 2008

Illegal character in Firefox

Firebug detected an illegal character while loading javascript, to fix this just have to open up the javascript with a proper texteditor and remove those illegal character. Pretty simple i guess. You can find more info from here

JQuery binding / unbinding event in Firebug

This article provides a good overview of what's going on in Jquery during bind/unbind of an event in firebug. http://ajaxian.com/archives/jquery-bondage#comments

WCF: This collection already contains an address with http scheme.

Ran into this problem earlier. The solution can be located here http://social.msdn.microsoft.com/forums/en-US/wcf/thread/12003fe3-917b-47fa-b768-a7914a374e66/ and http://geekswithblogs.net/robz/archive/2007/10/02/WCF-in-IIS-with-Websites-that-have-Multiple-Identities.aspx o

User control event/viewstate missing during postback

User control event/viewstate missing during postback Question : Some of your web control's events goes missing or cannot be caught when you load it in a user control? Answer: Always use the Control.UniqueID generated for you by ASP.Net when assigning it to a NAME property of your control. The complete Control.UniqueId is available when you assess this in OnPreRender stage. Check your Control.UniqueID which is render into the NAME property of your control on a HTML page. ASP.Net keeps track of the control using Control . UniqueID which makes events / viewstate works. If you override your UniqueID (for javascript manipulation) you might get this problem. Why does it work on your Page but not in user control? On a page, when your control is renders, it probably use name like “MyControl” but in user control this is automatically change to “ctl$_MyControl”. ASP.Net is no longer able to resolve your control id if you override your Control.ID. For example, I created a...

ASP.Net and JQuery

Anyone looking to get JQuery working on ASP.net can try this link : http://blog.dreamlabsolutions.com/post/2009/02/24/jQuery-document-ready-and-ASP-NET-Ajax-asynchronous-postback.aspx It describes everything you need to know to get it working together.

Using JQuery to retrieve elements outside of IFrame

Let's say you have a AJAX-enabled Dialog box and you used IFrame to load a page (php / aspx) . Retrieving any element outside of this page requires asking JQuery to go out of its scope. You can use the following code to retrieve element outside of your IFrame. $("#myDiv", top.window)

ASP.net ListView

The following examples give an overview of how to use ListView. Simple ListView <%@ Page Language="C#" AutoEventWireup="true" CodeFile="JL.aspx.cs" Inherits="JL" %> <%@ Register Assembly="SystemCore.CommonAppControls" Namespace="SystemCore.CommonAppControls" TagPrefix="cc1" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title></title> </head> <body> <form id="form1" runat="server"> <div> <asp:ListView ID="ListView1" runat="server"> <LayoutTemplate> <asp:PlaceHolder ID="itemPlaceholder" runat="server" /> </LayoutTemplate> ...

SSIS package throwing "the type initializer for 'System.Data.SqlClient.SqlConnection'

SSIS package throwing "the type initializer for 'System.Data.SqlClient.SqlConnection' threw an exception" I'm running SSIS package which references an assembly which calls a WCF web service. Everytime i run it, i get this weird "the type initializer for 'System.Data.SqlClient.SqlConnection' threw an exception". So i decided to check on app.config setting in the following files located in C:\Program Files\Microsoft SQL Server\90\DTS\Binn folder. a) DTExec.exe.config b) DtsDebugHost.exe.config c) dtshost.exe.config It has nothing to do with these configurations. Solution Try installing Microsoft .Net Framework 3.0 (in my case) and it solve my issue.

TransactionScopeOption vs TransactionScopeOptions

TransactionScopeOption in System.Transaction What is the differences between TransactionScopeOptions when we use it to create TransactionScope. We have the following option at our disposal. 1. TransactionScopeOption.Required TransactionScope created here is dependent on the root TransactionScope. 2. TransactionScopeOption.RequiresNew Creates an entirely new TransactionScope 3. TransactionScopeOption.Suppress TransactionScope created here is independent of root TransactionScope. Code below shows an example of how transactionScope takes effect when you stop your application in s1.Complete(); Data gets committed in TransactionScopeMixRequiresNew and TransactionScopeMixSupress method but not TransactionScopeMixRequires. using (TransactionScope s1 = new TransactionScope(TransactionScopeOption.Required)) { TransactionScopeMixRequires(); TransactionScopeMixRequiresNew(); TransactionScopeMixSupress(); /// if you stop your application here /// TransactionScopeMixRequiresNew and Tra...

Testing Code Contracts

Normally you would add reference to System.System.Diagnostics.Contracts to define your code contracts. To test it, here's how you do it. Download Contract checker from the following url http://research.microsoft.com/en-us/downloads/4ed7dd5f-490b-489e-8ca8-109324279968/default.aspx Install it and then open your Visual Studio 2010, goto Project Explorer's Properties. You are able to locate "Code Contracts" you're good to go :)

Nunit2.5 giving System.NullReferenceException when you're trying to add assembly?

Create your NUnit GUI project, ("C:\Program Files\NUnit 2.5\bin\net-2.0\nunit.exe") and then drag + drop your assembly into NUnit. That should do it. :) It is that easy.

Ferdinand : Scalable Query Result Caching for Web Applications

Summary : Uses disk caching method to enhance performance for database application. Users connect directly to a proxy. Each proxy consist of STATIC web cache. These servers are connected to each other via DHT and commmuicate with each other using publish / subscribe infrastructure. If a request is in the cache, it is retrieve immediately. If not, it is query from database. Cache is expected to be huge, therefore disk caching method is used. Ferdinand uses database template request and offline analysis to gurantee consistency of data in database. Notification is sent to master group and everybody synchronize their data. Prototype implementation Apache as the web server. MySQL - webservier Ferdinand - custom JDBC driver Pastry - DHT's related task. Scribed - Publish / Subscribe component

Cloud computing and Data Analysis.

Daniel Abadi in Data Management In the Cloud concludes that cloud computing is more suitable for large scale data analysis as oppose to transactional based system. Thus more research is expected in this area. Part of the reason why are as follows:- 1. Transactional application does not necessarily adopt a share nothing model. 2. Maintaining ACID properties for transaction over cloud is complex. More research in cloud computing's database evolve around the following areas: a) fault tolerance - continue query execution in the advent of failure b) heterogeneous cluster c) easy of use

Installing PHP on Apache 2.2.11 (Win32) PHP/5.2.5

Please download your Apache server and PHP. I'm assuming you installed your PHP into C:\PHP folder. Please modify your httpd.conf file located in your conf folder with the following settings. LoadModule php5_module "c:/php/php5apache2_2.dll" AddType application/x-httpd-php .php Restart your server. That's it. Apache Configuration Sample using Redirect Redirect /myservice http://localhost:8080/service Sample using Alias Alias /svc c:/test/appfolder Allow from all

Building Hadoop on Windows

Hadoop requires the following application :- 1) Ant (unzip and set PATH to point to this folder) 2) JDK (unzip and set PATH to point to this folder). I'm using JDK 1.6 Update 14 for this build. 3) Cygwin (svn + openssh) Download hadoop source code using svn from the following url: http://svn.apache.org/repos/asf/hadoop/core/trunk Go to the folder that you've download and build by typing ant (Press enter) That's all.