Disabling debug in other than dev environment - Sys.InvalidOperationException

If your web application using Microsoft Ajax (Ajax Control Toolkit), then you probably encounter common unknown javascript error as following:

jserror

Sys.InvalidOperationException: Handler was not added through the Sys.UI.DomEvent.addHandler method.

Cause:

Unknown handler error in MicrosoftAjax.debug.js

Resolution:

To ensure your server not prompting this debug message on your test or production server, just set debug=”false” in web.config. By doing this, ASP.net will not automatically include MicrosoftAjax.debug.js into one of the resource.axd

Desperate Stranger

I was signing up register as normal forum member in one of the famous forum in Malaysia which I do not want to mention the forum name. Early morning when I was checking email realized that I got a new private message from this forum and I was wondering does I know anyone in this forum.

Right after open up this private message and I read out the message, I am wondering is this message sending out by a guy or girl. That is just two answer here:

1. If is he, meaning that he is trying to making fool;

2. If is she, meaning that she is so desperate in love;

Anyhow, I just ignore this. You can have a look on the message below:

desperate-stranger

Consuming ASP.NET Handler By jQuery Ajax With JSON

Step towards Web 2.0 development nowdays, ajax is one of the important element in web development. There are various way of doing asynchronous call to server or web service to execute a job.

In this post, I am using jQuery to consume ASP.NET handler through a simple javascript codes. In the normal scenario, if client side requesting a simple string, server just have to return response context with plain/text. If you wish to return a set of data to be return in formatted string, you can either have the options like text/xml or application/json. My example code here will be using application/json with the assistance of third party component, Newtonsoft Json.

Scenario

“I Wish to use javascript to execute a job asynchronously to ASP.NET and receiving set of data in object. I do not wish to make my asynchronous call to any of my ASP.NET aspx pages because it is not a best practice. How can I do it?”

Expectation

Prerequisite Component

Solution File Structure

0001-20090505-120336

Download hellojson_050509_1229

Mouse Not Working After Installed VMware Tool

If you are in the case that your mouse is not working correctly in your VMware Virtual Machine, it is due to the conflict happened between Microsoft VM mouse driver and VMware VM mouse driver.

Resolution
========
1. Go to regedit and find out the key below:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Contro l\Class\{4D36E96F-E325-11CE-BFC1-08002BE10318}

2. Remove the value msvmmouf from the UpperFilters Regvalue.

And then reboot your OS.

Good luck

Re-install Visual Studio Templates

Whenever you found your item templates in visual studio are disappear, no need to re-install your visual studio. Just perform as picture below:

vstemplate

It will run silently for 1-2 minutes, do not close it while installing.

My Second Daughter - Xuan

Following up to my previous post of traveling back to Taiping to welcome my second daughter. Here it is the announcement of my second daughter name is Ter Jia Xuan (戴嘉萱). She like to talk a lot same as my first daughter, Kelly Ter. Luckily, Kelly like her new born sister very much. She will touch her softly and kiss her smoothly.

dsc00438

She is very enjoying when we left her two hands set free.

dsc00431

Hm… she can smile alike to her mummy.. As sweet as her mummy..

dsc00435

Ops… she almost sleeping soon. Maybe got some cool air from air cond and she feel relax.

Get Process ID from multiple application pool - iisapp

To attach process for remote debugging to server which contains multiple application pool, you need to attach to process name w3wp.exe. If your server containing multiple application then you will see multiple w3wp.exe. The only way to attach to correct w3wp, you are required to find out the process id of the particular application pool.

Just do the following:

0006-23-apr-09-030608-pm

Meeting my second child

Finally, I going to travel back to my hometown tomorrow morning to meet my wife and my daughter. They have been waiting me for very long, and I missing them as well.

I feel very excited and looking forward to see them immediately. This time, I will meet with my second child who going to be part of my family soon.  I feel proud with my wife who has suffering for 9 months of pregnancy, I will appreciate it.

It is been long time I didn’t take long leave as this time is an opportunity to take my time to accompany with my family. Althought it is not a family trip visiting some other countries, but it is very satisfying spending time in my hometown especially the foods in town.

I will re-update my blog with more info about my second child soon.