2009年9月10日 星期四

Static

常常記不起來,還是先Blog 起來好了
Sample 比較容易懂


Static Constructors
public class Bus
{
// Static constructor:
static Bus()
{
System.Console.WriteLine("The static constructor invoked.");
}

public static void Drive()
{
System.Console.WriteLine("The Drive method invoked.");
}
}

A slightly more informative example would be:
static void Main()
{
Bus.Drive();
Bus.Drive();
}
which gives the output:
The static constructor invoked.
The Drive method invoked.
The Drive method invoked.
Thus showing that the constructor is only called once, even though 'Drive()' was called twice.




***Static Variables***
Please enter 5 numbers to be summed
Enter a number: 12
The current total is 12
Enter a number: 23
The current total is 35
Enter a number: 34
The current total is 69
Enter a number: 45
The current total is 114
Enter a number: 56
The current total is 170
Program completed

2009年8月19日 星期三

一堆貳ㄟ司ㄟ司林克

http://feeds.feedburner.com/benl
http://www.aboutcode.net/SyndicationService.asmx/GetRss
http://adrianba.net/rss.aspxhttp://feeds.feedburner.com/CirrusMinor
http://feeds.feedburner.com/AyendeRahien
http://community.bartdesmet.net/blogs/bart/Rss.aspx
http://www.flux88.com/SyndicationService.asmx/GetRssCategory?categoryName=NHibernate
http://benjismith.net/index.php/feed/
http://blog.stackoverflow.com/feed/
http://www.mperfect.net/__BLOG_ARCHIVE/rss.xml
http://www.code-magazine.com/CodeRSS.aspx
http://feeds.feedburner.com/codinghorror/
http://feeds.feedburner.com/igloocoder
http://www.larkware.com/DailyGrind.xml
http://feeds.feedburner.com/Carnage4Life
http://feeds.feedburner.com/arcware
http://davidhayden.com/blog/dave/Rss.aspx
http://davidpallmann.spaces.live.com/feed.rss
http://blogs.msdn.com/devdev/rss.xml
http://feeds.feedburner.com/DidItWithDotNet
http://blogs.msdn.com/dsyme/rss.xml
http://feeds.encosia.com/Encosia
http://jeremyjarrell.com/Rss.aspx
http://feeds.feedburner.com/testdrivennewslinksnews=10
http://weblogs.asp.net/infinitiesloop/atom.aspx
http://blog.goinsane.co.uk/SyndicationService.asmx/GetRss
http://www.intellectualhedonism.com/SyndicationService.asmx/GetRssCategory?categoryName=dnr
http://www.intellectualhedonism.com/SyndicationService.asmx/GetRssCategory?categoryName=dnrtv
http://www.intellectualhedonism.com/SyndicationService.asmx/GetRssCategory?categoryName=Hanselminutes
http://www.intellectualhedonism.com/SyndicationService.asmx/GetRssCategory?categoryName=RunAs%20Radio
http://blogs.tedneward.com/SyndicationService.asmx/GetAtom
http://feeds.feedburner.com/Iserializable
http://www.jameskovacs.com/blog/SyndicationService.asmx/GetAtom
http://feeds.feedburner.com/JPBoodhoo
http://www.jnsk.se/weblog/rss.xml
http://www.joelonsoftware.com/rss.xml
http://feeds.feedburner.com/callvirt
http://www.yoda.arachsys.com/csharp/rss.xml
http://blog.kickin-the-darkness.com/feeds/posts/default
http://www.julmar.com/blog/mark/SyndicationService.asmx/GetRss
http://www.sellsbrothers.com/news/rss2.aspx
http://blogs.msdn.com/mharsh/atom.xml
http://feeds.feedburner.com/DanielMoth
http://blogs.hibernatingrhinos.com/nhibernate/Rss.aspx
http://feeds.feedburner.com/developernotes
http://feeds.feedburner.com/NotesFromAToolUser
http://www.pluralsight.com/community/blogs/fritz/Rss.aspx
http://polymorphicpodcast.com/podcast/feed/
http://feeds.feedburner.com/SamGentile
http://weblogs.asp.net/ScottGu/Rss.aspx
http://channel9.msdn.com/Media/Screencasts/feed/wmv/
http://www.sdnug.org/rss.xml
http://blogs.interfacett.com/simon/atom.xml
http://www.sleepoverrated.com/SyndicationService.asmx/GetRss
http://forums.construx.com/blogs/MainFeed.aspx?GroupID=5&Type=AllBlogs
http://steve-yegge.blogspot.com/rss.xml
http://feeds.feedburner.com/UdiDahan-TheSoftwareSimplist
http://channel9.msdn.com/Media/Videos/feed/wmv/
http://feeds.feedburner.com/visualcomplexity
http://www.michaelnygard.com/blog/atom.xml
http://hammett.castleproject.org/?feed=rss2

2009年8月2日 星期日

洗衣機進水幫浦

昨天晚上把洗衣機的近水幫浦拆開來看,
因為他是雙頭的進水,所以就把兩個頭換過來,
沒想到它就好了,洗衣機竟然就這樣修好了,
松下問童子,這樣的動作竟然要價兩千多,
以下解釋一下進水幫浦的原理,
進水幫浦其實就是用電磁鐵的原理,
幫浦本身是有一小根鐵棒,插進用黑色的管狀物(我想應該是用漆包線纏繞的)
利用電流正負控制幫浦開合,大概是這樣吧。


2009年7月26日 星期日

敗家的那一刻

天使跟惡魔正在打架
天使:要花一萬二耶,花這個錢要做什麼? 存起來不是很好,當初的想法是有得拍就好,拍個記錄而已阿,幹嘛還要花錢再買鏡頭?
惡魔:買啦買啦! 室內每次都拍出來暗暗的,拍食物也拍得不好吃,敗下去,室內就靠這一顆啦!!

我:你他媽的就買下去就對了,想那麼多,每天都在那邊看mobile01,Y拍,... 買下去就不會有那麼多煩惱了 ...

於是,買了第一顆定焦鏡,http://www.sigma.net.tw/28_18.htm
原本是想買閃燈的,不過在家裡一直試不出閃燈的效果,所以還是決定敗定焦鏡。

試拍鐘擺櫻桃,還可以看到清楚的櫻桃。

今天就去辣妹店買西格瑪,因為問到的價格是那邊最便宜,
今天服務的辣妹,穿著有點像女僕的裝扮,一直用娃娃音幫我介紹,
我是一整個傻眼,暗~~ 可以正常一點嗎? 我又不是三歲 ...
進去出來,應該不到五分鐘,有我這種客人真好,一天就有百萬入帳 ...
應該也來開這樣的店,日入百萬!!!

2009年7月14日 星期二

IE6中出現「無法設置selected屬性」的bug及解決方法

如果在IE6中設置select控件的selected屬性的時候,會提示「無法設置selected屬性。未指明的錯誤。」

後來查了一下資料,發現這個錯誤在IE5.5、7及Firefox等瀏覽器下面沒有問題,唯獨IE6下有如下的提示。後來有人找到了一個解決的方法,就是設置selected屬性的時候使用setTimeout函數設定一個時間即可,代碼如下:

var selectObj = document.getElementById('selectId');

// 使用setTimeout之後問題解決

setTimeout(function() { selectObj.options[1].selected = true;}, 1);

2009年7月13日 星期一

Facebook台灣上星期爆增8.8萬使用者,下個月即將突破100萬!

轉載自 Mr.6 http://mr6.cc/?p=3310

 

Facebook目前在台灣的使用者,竟然已經不知不覺的飆速成長到高達74萬人,目前在台灣的會員數已經是噗浪的二倍

而且Facebook這個月台灣顯然正處盛年,以公牛般的衝刺速度往上撞升,讓我們簡單幫它計算一下──

如果以上周8.8萬人來看,我們會畫出一條往天空飆升的曲線!如果每周都和上星期一樣,再過三∼四個星期,也就是八月初,

Facebook在台灣就會突破100萬的使用者用戶總數。再讓這頭公牛如此「撒野」下去,只要不出半年的時間,沒錯,

農曆新年都還沒到、年終獎金都還沒發、尾牙都還沒辦,Facebook在台灣就會匡啷匡啷達到堂堂「300萬會員」

 

我們可以歸納出4個要點

 

一、台灣潛在使用者大軍,竟是「上班族」而非學生族

二、台灣(與大陸內地)的「高中生」還有很大開發空間

三、韓國是台灣創業家的「海外實驗室」

四、印尼榮登「人頭庫」的最佳人選

 

無論這74萬名Facebook台灣會員代表什麼,今年的台灣網路界,肯定是愈來愈精彩了!企業可以用網路方面也愈來愈精彩了。

上周才說NET-MBA系列課程即將加入「微網誌成功案例」,跟趨勢的確很累,雖然自己坐不到雲霄飛車,

「欣賞」雲霄飛車、親眼看到它一飛沖天的全部過程也算蠻痛快的。

2009年6月29日 星期一

變形金剛II

說真的 看完預告片 都還不知道這一部想要講的故事事長什麼樣子
看完的感想是 有點像國家寶藏II 的感覺,
就是有一個線索,然後區挖掘出歷史的東西,
對戰的戲碼感覺上也滿多的,
笑點也滿多的,
預告片感覺是要讓故事與山姆上大學有關,
看起來又好像可以沒有關係,
大黃蜂依舊還是在山姆身邊,並沒有因為上大學,而不在山姆身邊保護他。
大學遇到的正妹狐狸精,也沒有真正破壞山姆跟密琪的感情,
兩個人從誤會到和好只有三分鐘,不像一般的男女朋友吵架或誤會的片段,
那個狐狸精的出現,感覺上也沒有達到狐狸精的功能。
如果有第三集(密卡登沒死),可能會更精彩吧。(像神鬼奇航一樣)

2009年6月10日 星期三

農委會Logo設計比賽

http://kminter.coa.gov.tw/mp.asp?mp=1

 

農業知識入口網logo設計競賽,主要是透過活動的進行,

將農業知識入口網印象轉化成一般民眾容易接受的logo識別,

設計出能代表農業推廣的精神,作為未來相關活動、行銷及宣傳之應用。

 

凡對此競賽有興趣之個人或團體,且具中華民國國籍,不限年齡、職業、

性別皆可報名參加,以團隊方式參賽者,請指派一名授權代表,

以代表填寫報名表資料、簽署著作權轉讓同意書、得獎獎金領取等;

得獎獎金自行分配,參賽者不得冒名頂替,繳交作品前須先成為本網站會員。

() 活動時間:9868日至98626日截止

() 公布得獎名單: 將於活動截止一個月內公布於網站

() 由主辦單位邀請專家學者組成評選委員會進行評選

() 評分標準:

  1. 主題表達:40
  2. 視覺效果:40
  3. 創意性:20

 

1. 金獎(1):新台幣25000元及獎狀乙張

2. 銀獎(1):新台幣15000元及獎狀乙張

3. 銅獎(1):新台幣5000元及獎狀乙張

 

2009年6月9日 星期二

you eat an elephant one bite at a time, and damn the torpedoes.

you eat an elephant one bite at a time, and damn the torpedoes.

這句話不知道中文的解釋是什麼?
絕對不是咬一口大象那麼簡單,先記下來,有機會再查看看是什麼意思。