Dec 28, 2009

Turn Off AutoPlay

The autoplay function is convenient but sometimes annoying. Turn off the autoplay function adn let yourselft decide your next action:
1, use gpedit.msc
2, under computer configuration->Administrative Templates->System, on the right part there is a item "Turn off Autoplay".
3, Double click that and choose "Enable" on all devices.

Dec 18, 2009

Google Wave Part 2

Although I didn't name the previous article about Google Wave as part 1, which means I will keep on trying this new stuff. Today I watched a Google wave introduction accidentally, but I would I feel very lucky that I have watched this video.

The link is here http://www.youtube.com/watch?v=v_UyVmITiYQ.

It introduced the wave functions link auto correction, typing chasing, replaying wave, embedded wave in Blog, document collaboration etc. I should say, it WOW, amazingly fancy. It's very attractive. It's cutting edge. It is worthy all your beautiful words. Applaud on this great product!

I will work hard to join the honored Google team and make my own cool products to the world!

PS: My good friends, if you have watched the video and it touched you. Please come to me for an invitation.
the google wave is a little slow. Hehe. Nothing is perfect.

Dec 17, 2009

Google Wave

I have got seven invitations of Google Wave. My friends, if you by chance visit my blog, I can give you an invitation.

Find a interesting way to search public wave - in the search box, use "with:public lang:zh".
Then Just Wave...

Dec 15, 2009

Java Applet Chinese Font Settings

If you are using a English language Windows XP, the Java Applet might not display Chinese normally. The method to solve this:
1) Put one Chinese font file which is in C:\Windows\Fonts\ to $JAVA_ROOT/jre/lib/fonts/fallback/ , for example you choose SimSun
$JAVA_ROOT means JDK installation directory.

2) Open control pannel, click Java, under Java->Java Runtime Settings->View,
Add -Dfile.encoding=gbk in the Runtime Parameters.

It will be OK.

Dec 14, 2009

Source Insight Font Setting

The default font of Source Insight is verdana, which looks strange.
The recommended font is courier new, and it looks beautiful. You can change to it through: Option->Document Options->Screen Fonts->and choose Courier New, 10.

Dec 11, 2009

MSN No Response after Launch [Weird]

A very weird problem, the newly installed latest version MSN can not run! When I try to run it, MSN will lose response after it prompts the user list.

After I searched in web, the solution is:
Unplugged your charger and after a few seconds plug it again. It really soved this problem. What a weird software!

Dec 9, 2009

Manually Create Proxy File

In many companies, we have to use proxy to connect to internet in that company needs to do the center control about web access, content filter etc.
So how to manually add your proxy settings together with the company proxy settings?
1, input the proxy setting address in the IE. In my case, I have input http://autocache.**.com, and a file download dialog will be prompted. Save this file as my.pac in C drive root. Of course you can put it in any place you want.
2, open this file with txt edit, for example notepad.

//Modified by Sai
if (shExpMatch(host, "*.blogspot.com"))
return "PROXY web-proxy.sgp.**.com:8080";
This means if the expression matches *.blogspot.com use your specified proxy.
3, open IE, in tools->Internet Options->Connections->LAN settings->check use automatic configuration script, input address file://c:/my.pac

That's it.

Nov 13, 2009

Visual Studio 2005 convert to 2008 error: The project is under source control

Today I solved a problem when I tried to covert visual studio 2005 project to visual studio 2008 project, I met a prolem "The project is under source control". My solution is:
1, make all the read only files to readable (uncheck the readonly checkbox)
2, open the *.csproj file with UltraEdit, and remove the four lines of tags which begin with "Scc"

...
...
...
...

No, it's OK now.

Nov 12, 2009

ClearCase Delete Stream on the Server

Thanks my colleague- Heberling, John
He wrote a very helpful script.

Here are the steps:
1, Delete the local view in CCRC
2, use the script /h/clearadm/desc_stream.ksh zhang5_NPAT_R2_4_SP_SPR2 /neo/neoview_pv to see whether there are views or other dependencies on it. Only when all the views or dependencies are deleted, you can delete the stream.
3, use /h/clearadm/rmstream.ksh zhang5_NPAT_R2_4_SP_SPR2 /neo/neoview_pv to delete stream. It will prompt confirmation, you could type in yes.

More details:
a) desc_stream.ksh is the script to run this command:
"cleartool desc stream:zhang5_NPAT_R2_4_SP_SPR@/neo/neoview_pv", because @ sign can't be input in the system.
b) to use the command cleartool, you should add /opt/rational/clearcase/bin to the path. export PATH="/opt/rational/clearcase/bin:$PATH"
c) to log on server, we use: telnet servername..., for example, telnet cacview1, and then logon with your ClearCase user ID and password.

rmstream.ksh is the script to run this command:
cleartool rmstream zhang5_NPAT_R2_4_SP_SPR@/neo/neoview_pv

Nov 3, 2009

IBM Rational ClearCase Remote Client Language Settings

Language problem for CCRC-
IBM ClearCase Remote Client gets the location settings of the computer from control panel settings, so if in control panel settings, you are in China, the CCRC will launch as a Chinese version, but how can I use the English version?
Here is the method:

Start->All Programs->IBM Rational-> Right click the icon of CCRC,
add -Duser.language=en_US, then the whole string looks like

"C:\Program Files\IBM\Rational\ClearCase701\CCRC\ccrc.exe" -vmargs -Xj9 -Duser.language=en_US

Then it works in English version.

Oct 26, 2009

How to Solve Ant Error - Unable to locate tools.jar

The problem is: Unable to locate tools.jar. Expected to find it in C:\Program Files\Java\jre6\lib\tools.jar

Step 1: set JAVA_HOME environment variable to your JDK install directory

Step 2: restart cmd window, the windows doesn’t recognize it before cmd window is restarted.

How to install ant

1.First,You must have JDK installed first.

2.Get the ANT for windows here:
http://ant.apache.org/bindownload.cgi, choose latest version with zip package

3.After download ANT,extract zip package in (for example) C:\Program Files\Apache\Ant


4.Set ANT_HOME

■Right click My Computer icon
■Choose properties
■Choose Advanced Tab
■Choose Environtmen Variables Button
■In the System Variables, click New Button
■Give the Variable Name:ANT_HOME
Give the Value: C:\Program Files\Apache\Ant
■Click OK
Then,we’ll add new ANT_HOME path,

Find PATH in the Variable Column in System variables frame

■After found, click Edit button
■Then, add the following text in the bottom of Variable value:
%ANT_HOME%\bin;

■Click OK to finish
5.Check wheter ANT works correctly or not.
In the command prompt, type:

ant -version

if the result text is something like:

Apache Ant version 1.7.1 compiled on June 27 2008 then your ANT is work correctly on your Windows

6.The end.

Oct 20, 2009

Delete AliWangWang Right Extention

Regedit 32
Delete

HKEY_CLASSES_ROOT\CLSID\{0DE1378D-F811-40E6-B60A-1CC56F57D3E9}\InprocServer32 The items contain aliimext.dll.

If ali wangwang updates, you need to repeat this.

Oct 10, 2009

Use registry to clean right context menus

Some applications will install his quick launch items in the mouse right click menu, but many of the quicklinks are useless.
So let's begin to clean them and make our computer world clean as white snow.

Type 1: clean right menu item
1, use registry(run regedit.exe)
2, expand [HKEY_CLASSES_ROOT\*\shellex\ContextMenuHandlers], find the item which you want to remove, like NamipanExt etc., delete it.

Type 2: clean right click new item
1, use registry(run regedit.exe)
2, expand [HKEY_CLASSES_ROOT], ctrl+F, find ShellNew, if you don't need it, rename it to ShellNewOld.

Update on March 17, 2011-
Type 3: clean right click IE item
1, use registry(run regedit.exe)
2, expand [HKEY_CURRENT_USER]\Software\Microsoft\Internet Explorer\MenuExt
Delete something like Thunder... Udown...
Udown? You done.

Update on November 14, 2012
Now a great tool can support this: CCleaner
CCleaner is a tool that can help you clean clean your system, like temporary files  cache etc., fix registry problems, and uninstall/install software etc.

To clean context menu, we can
1. click tools icon
2. Click StartUp area
3, In "Context Menu" we can enable/disable or delete the items.



Jul 21, 2009

<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<ContactManager.Models.Contact>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
<title>Index</title>
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">


<table class="data-table" cellpadding="0" cellspacing="0">
<thead>
<tr>
<th class="actions edit">
Edit
</th>
<th class="actions delete">
Delete
</th>
<th>
Name
</th>
<th>
Phone
</th>
<th>
Email
</th>
</tr>
</thead>
<tbody>
<% foreach (var item in Model)
{ %>
<tr>
<td class="actions edit">
<a href='<%= Url.Action("Edit", new {id=item.Id}) %>'><img src="../../Content/Edit.png" alt="Edit" /></a>
</td>
<td class="actions delete">
<a href='<%= Url.Action("Delete", new {id=item.Id}) %>'><img src="../../Content/Delete.png" alt="Delete" /></a>
</td>
<th>
<%= Html.Encode(item.FirstName) %>
<%= Html.Encode(item.LastName) %>
</th>
<td>
<%= Html.Encode(item.Phone) %>
</td>
<td>
<%= Html.Encode(item.Email) %>
</td>
</tr>
<% } %>
</tbody>
</table>
<div class="divContactList-bottom">&nbsp;</div>
</asp:Content>