<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
<channel>        <title><![CDATA[Jeff 隨手記]]></title>
        <link><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh]]></link>
        <description><![CDATA[分享程式的技術,工作的經驗,生活的看法,這裡就是我的筆記本.]]></description>
  <lastBuildDate>Thu, 29 Oct 2009 22:51:19 +0800</lastBuildDate>
        <language>zh-tw</language>         <item>
            <title><![CDATA[該死的抽神經,說好的麻藥呢!!!]]></title>
            <link><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2057]]></link>
            <description><![CDATA[牙齦浮腫了幾天,今天撥空去看了牙醫,沒想到醫生說<br><br>醫生 : 你這是典型牙周病哦!!<br><br>我 : 蝦米!!!!!!<br><br>醫生 : 先去照個X光看看.<br><br>我 : .....X光?<br><br>進了一個小房間,一下就拍好了.<br><br>醫生 : (指著X光片)你看,骨頭都沒有了.<br><br>我 : .......<br><br>醫生 : 我先幫你抽神經,如果沒用,就只好整個拔掉,裝假牙了.<br><br>我 : 大驚!!!!!!!!!!!!!!!!!!!!!!!!!!!!<br><br>接下來醫生就在我的口中&quot;開工&quot;.<br><br>突然間一陣劇痛!!!!!!!!!!<br><br>醫生 : 不要動哦.<br><br>我 : 什麼,開始抽了???沒有心理準備的說,來的真突然,但怎麼沒有上麻藥??<br><br>醫生 : 你再忍一下哦,不用動,這樣我不好弄.<br><br>我 : 心裡的髒話全出來了,這麼痛,我怎麼可能一動也不動,但關公削骨療傷,還一邊下棋,完全不會所動,我只是抽神經,忍~~~~~~~<br><br>醫生 : 再去拍個X光吧.<br><br>我 : 還拍???<br><br>拍完又回去躺著抽.<br><br><br>持續的痛,一直忍在抓狂的臨界點.<br><br><br>這時,一隻蚊子在我眼前飛啊飛,之後從下方消失在我的視線,沒多久....<br><br><br><br>你老師咧!!!!!!!!!!!!!<br><br><br>叮我的腳趾頭!!!!!<br><br><br>我....流淚了.....<br><br>醫生 : 沒關係,快好了.<br><br>我 : 含著眼光,看著天花板想著...................<br><br><br><br><br><br>你老師卡好,該死的蚊子,就不要讓我抓到!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!<br><br><br><br>醫生 : 再去拍個X光吧.<br><br>我 : 蝦米???又拍,是要當寫真嗎?<br><br>拍完又接者回去動工,最後在我的牙內插著幾根針.<br><br><br>等它消腫,下週還要去做牙套.<br><br>銀色的要6,500,白色的要7,500...<br><br><br><br>拍了這麼多X光,不知道我會不會突變,明天我的眼睛會發出X光....<br><br>不知道是痛,還是怎麼,頭一整個昏,可能腦細胞被X光殺了不少...<br><br><br>哀事完了嗎??<br><br><br><br>還沒.<br><br><br>之後又去剪頭髮,沒想到泡泡跑到我的左眼裡,現在一整個紅....<br><br><br>回來後,看到朋友發噗 : 你搬家到blogspot了嗎,還是被盜文了?<br><br>我 : .........淡淡的淚光又流了出來....<br><br><br><br><br><br><br><br><br>因為....泡泡好刺眼.....<br><br><br>今天是什麼鬼日子啊....<br>]]></description>
            <pubDate>Thu, 29 Oct 2009 22:30:25 +0800</pubDate>
            <guid><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2057]]></guid>
         </item>         <item>
            <title><![CDATA[我又被整個大盜文了]]></title>
            <link><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2056]]></link>
            <description><![CDATA[　　前段時間最多只是看到一篇被PO到討論區,不過這次看到的比較扯,一次被盜了數十篇到他個人Blog,看了一下他的個人簡介,學歷真高啊,中原資工研究所,程式寫了十多年,好&quot;偽&quot;的學經歷啊...<br><br>一眼望去,還都是我的...<br><br><img src="http://tw.blog.yahoo.com/photo/photo.php?id=hyO3_NyYFRHK..Q8qsNVbA--&amp;photo=tn_F23_20091029093805659.jpg"/><br><br><br>中原資工研究所,十年的程式撰寫經驗....<br><img src="http://tw.blog.yahoo.com/photo/photo.php?id=hyO3_NyYFRHK..Q8qsNVbA--&amp;photo=tn_F23_20091029093809484.jpg"/><br><br>所以你拿你的高學歷跟豐富經歷來這樣轉別人的文??<br><img src="http://tw.blog.yahoo.com/photo/photo.php?id=hyO3_NyYFRHK..Q8qsNVbA--&amp;photo=tn_F23_20091029093810187.jpg"/><br><br>朋友還以為我搬家到Blogspot,急著發噗關心我,還好看到你的&quot;勿忘影中人&quot;的照片,他們才放心,原來我沒有搬家.<br><img src="http://tw.blog.yahoo.com/photo/photo.php?id=hyO3_NyYFRHK..Q8qsNVbA--&amp;photo=tn_F23_20091029093811749.jpg"/><br><br>Joseph (Jen-Ho Chang)兄,中原資工研究所,程式寫了十多年都白學了嗎?<br><br>　　因為我是非本科的專科生,那些文是我從不懂程式,學了3年才寫出那些文章,每篇文章我都花了不少時間,你這麼一抄,你的學歷跟經歷在這一瞬間就變&quot;狗屎&quot;,我完全無法相信你的學經歷~<br><br>而且,你的Blog是被植入木馬了嗎?竟然會跳出這個訊息.<br><br>&quot;g9677602.blogspot.com可能會嘗試竊取您的資訊。&quot;<br><br>Mcafee SiteAdviisor 也不認同你...你的行為,連Mcafee也知道,果然是會&quot;竊取您的資訊&quot;.....<br><br><br><br>唉....<br>]]></description>
            <pubDate>Thu, 29 Oct 2009 22:02:51 +0800</pubDate>
            <guid><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2056]]></guid>
         </item>         <item>
            <title><![CDATA[[小工具] 定時釋放程式記憶體]]></title>
            <link><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2049]]></link>
            <description><![CDATA[<p>這段時間的Facebook小遊戲似乎已成為全民運動,很多人都在玩FB上的小遊戲,但上面的小遊戲品質似乎也都不是那麼的好,最明顯的例子就是 Restaurant City餐廳城市,其實我是沒在玩,之所以會知道這個問題,也是因為老婆最近玩的很勤,今天老婆一如往昔的打開他的專屬電腦玩FB的RC,只是今天她終於 忍不住跟我抱怨電腦好慢,當下過去檢查了一下效能問題,CPU的負載是有點高,都在80%以上,但讓我吃驚的並不是CPU的問題,而是記憶體的耗用量,當 時所看到的耗用量已達4百多MB,而且還在持續上升,原本已為是Firefox的問題,就算Safe Mode也是沒有改善,改用IE7也還是一樣的問題,當下只能說是小遊戲的問題,可是老婆要玩,這個理由似乎無法滿足她,只好想辨法解決記憶體的問題.</p>
<p>&nbsp;</p>
<p>記得過去有找過不少的記憶體管理工具,突然想到有一個工具或許可以&quot;輔助(減輕)&quot;用量,而這個小工具就是 <a href="http://main.kerkia.com/Tools/Minimem/Description.aspx" target="_blank">Minimem</a> ,這個小工具雖然是英文的,但介面並沒有很複雜.</p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0910/6f3bdf071f90_16C2/image_2.png"><img title="image" style="border-width:0px;display:inline;" alt="" src="http://files.dotblogs.com.tw/jeff-yeh/0910/6f3bdf071f90_16C2/image_thumb.png" border="0" height="409" width="504"/></a> </p>
<p>上方工具列 :</p>
<p>Optimize Now : 馬上進行記憶體釋放</p>
<p>Reset Options : 還原預設值</p>
<p>Refresh : 更新資訊 (比如說,firefox是在minimem開啟之後才執行的,一開始沒在All active processes內,按下Refresh就會出現)</p>
<p>Task Manager : 開啟工作管理員</p>
<p>Shut Down : 關閉 Minimem (不是電腦關機,剛開始我也誤會...)</p>
<p>&nbsp;</p>
<p>中間兩個窗格 :</p>
<p>左邊的Optimized processes : 會進行記憶體管理的程式清單</p>
<p>Clear unchecked items : 將沒有打勾的項目清除</p>
<p>右邊的All active processes : 所有目前執行中的程式</p>
<p>Hide if memory : 如果這個項目打勾,清單只會列出記憶體耗用高於右方數字以上的程式.</p>
<p>中間的Button [ &lt; ] : 就是將右邊選擇的程式加到左邊的Optimized清單</p>
<p>&nbsp;</p>
<p>下方的Minimem options :</p>
<p>Optimize memory every : 每隔幾秒進行一次調整</p>
<p>Do not optimize the foreground process : 打勾的話,只會調整背景執行的程式,前景操作中的就不會調整.</p>
<p>Do not optimize if overal RAM available &gt; : 打勾的話,如果RAM還有多少以上,就不會進行程式調整.</p>
<p>&nbsp;</p>
<p>在常駐程式的小ICON按下右鍵</p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0910/6f3bdf071f90_16C2/image_4.png"><img title="image" style="border-width:0px;display:inline;" alt="" src="http://files.dotblogs.com.tw/jeff-yeh/0910/6f3bdf071f90_16C2/image_thumb_1.png" border="0" height="129" width="173"/></a> </p>
<p>Settings : 開啟上方的Minimem settings畫面</p>
<p>Start with Windows : 開機時,自動載入</p>
<p>Help : 說明</p>
<p>About : 關於</p>
<p>Shut down Minimem : 關閉程式</p>
<p>&nbsp;</p>
<p> 剛幫老婆裝了上去,並做好相關的設定,把Firefox及Iexplore加進去,之後開始玩FB的RC,記憶體果然還是一樣持續上升,但30秒一到,就 會釋放到不少記憶體,所以就不怕玩個小遊戲,就又把記憶體吃光光,開始跑硬碟的Page file,這樣硬碟會掛的更快....</p>
<p>&nbsp;</p>
<p>程式下載 : <a href="http://main.kerkia.com/Tools/Minimem/Download.aspx" target="_blank">Minimem</a></p>]]></description>
            <pubDate>Sat, 03 Oct 2009 01:38:02 +0800</pubDate>
            <guid><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2049]]></guid>
         </item>         <item>
            <title><![CDATA[GARMIN nuvi 265 WT 更新3.4版心得]]></title>
            <link><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2047]]></link>
            <description><![CDATA[　　最近Garmin又推出了新的更新(推的速度還真頻繁),原本舊版的使用上並沒什麼問題,但就是想說有新的,就更新上去玩玩看,從官網下載了3.40的版本回來安裝,這幾天的試用心得還不錯.<br><br>1.衛星定位速度 : 變快了,原本的速度就在我可接受範圍,沒想到更新後變的更快.但說快了幾秒,說真的,干擾因素太多,很難給個準確時間,但可以確定的是變快了.<br><br>2. 準確度 : 誤差都一樣,所以沒什麼感覺.<br><br>3.重新規劃速度 : 這點真的是大改進,前一版是2X% 4X% 7X%的這樣慢慢跳,這一版快了有一半以上吧,這點很重要,有時在超過路口時,還在等它規劃,心裡真是XXX到極點,但3.40版改善了很多.<br><br>4. 莫拉克封閉路況 : 還沒機會用到這麼功能,但有這樣的功能也是就感心咧~<br><br>　　用了這幾個月,心得是還不錯,藍芽跟手機連線功能反而是最常用的,開車可以用不拿手機,一樣放在包包裡,兩台在連線範圍內,它就會自動連線,完全不用去手動(除了第一次的設定),所以接電話就可以直接用GPS來接,本來想買Sony Ericssion HCB-120 (一台也要3,550),現在省下來了,而且這種可更新程式的,支援性應該會比較好吧,未來可以用更新的方式,來支援新的手機~<br>]]></description>
            <pubDate>Wed, 23 Sep 2009 22:49:59 +0800</pubDate>
            <guid><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2047]]></guid>
         </item>         <item>
            <title><![CDATA[MTOM檔案的續傳功能(三) Client 端程式介紹]]></title>
            <link><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2046]]></link>
            <description><![CDATA[<p>　　上一篇寫了MTOM Server端的部份,這次要寫的就是Client端的程式要怎麼跟Server互動,也就是最後一篇,廢話不多說,馬上進入正題,Client端的程式跟Server端一樣,要用WSE的Configuration Tool來設定,而Web Service是存在Web.Config,那Client端的WinForm就是存在app.config</p>
<div style="border:1px solid rgb(204, 204, 204);padding:4px;color:rgb(0, 0, 0);background-color:rgb(238, 238, 238);font-family:Verdana, 細明體;width:98%;line-height:16px;font-size:10pt;">?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;<br><font color="#0000ff">&lt;</font><font color="#800000">configuration</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">configSections</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">sectionGroup</font> <font color="#ff0000">name</font><font color="#0000ff">=&quot;applicationSettings&quot;</font> <font color="#ff0000">type</font><font color="#0000ff">=&quot;System.Configuration.ApplicationSettingsGroup, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&quot;</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">section</font> <font color="#ff0000">name</font><font color="#0000ff">=&quot;MTOMClient.Properties.Settings&quot;</font> <font color="#ff0000">type</font><font color="#0000ff">=&quot;System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&quot;</font> <font color="#ff0000">requirePermission</font><font color="#0000ff">=&quot;false&quot;</font> <font color="#0000ff">/&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">sectionGroup</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">sectionGroup</font> <font color="#ff0000">name</font><font color="#0000ff">=&quot;userSettings&quot;</font> <font color="#ff0000">type</font><font color="#0000ff">=&quot;System.Configuration.UserSettingsGroup, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&quot;</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">section</font> <font color="#ff0000">name</font><font color="#0000ff">=&quot;MTOMClient.MTOMSet&quot;</font> <font color="#ff0000">type</font><font color="#0000ff">=&quot;System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&quot;</font> <font color="#ff0000">allowExeDefinition</font><font color="#0000ff">=&quot;MachineToLocalUser&quot;</font> <font color="#ff0000">requirePermission</font><font color="#0000ff">=&quot;false&quot;</font> <font color="#0000ff">/&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">sectionGroup</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">section</font> <font color="#ff0000">name</font><font color="#0000ff">=&quot;microsoft.web.services3&quot;</font> <font color="#ff0000">type</font><font color="#0000ff">=&quot;Microsoft.Web.Services3.Configuration.WebServicesConfiguration, Microsoft.Web.Services3, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35&quot;</font> <font color="#0000ff">/&gt;</font><br>&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">configSections</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">applicationSettings</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">MTOMClient.Properties.Settings</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">setting</font> <font color="#ff0000">name</font><font color="#0000ff">=&quot;MTOMClient_MTOMWS_ServiceMTOM&quot;</font> <font color="#ff0000">serializeAs</font><font color="#0000ff">=&quot;String&quot;</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">value</font><font color="#0000ff">&gt;</font>http://localhost:2448/MTOMWebService/ServiceMTOM.asmx<font color="#0000ff">&lt;/</font><font color="#800000">value</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">setting</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">MTOMClient.Properties.Settings</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">applicationSettings</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">userSettings</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">MTOMClient.MTOMSet</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">setting</font> <font color="#ff0000">name</font><font color="#0000ff">=&quot;FolderPath&quot;</font> <font color="#ff0000">serializeAs</font><font color="#0000ff">=&quot;String&quot;</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">value</font><font color="#0000ff">&gt;</font>c:&#92;temp<font color="#0000ff">&lt;/</font><font color="#800000">value</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">setting</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">MTOMClient.MTOMSet</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">userSettings</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">system.web</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">webServices</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">soapExtensionImporterTypes</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">add</font> <font color="#ff0000">type</font><font color="#0000ff">=&quot;Microsoft.Web.Services3.Description.WseExtensionImporter, Microsoft.Web.Services3, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35&quot;</font> <font color="#0000ff">/&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">soapExtensionImporterTypes</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">webServices</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">compilation</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">assemblies</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">add</font> <font color="#ff0000">assembly</font><font color="#0000ff">=&quot;Microsoft.Web.Services3, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35&quot;</font> <font color="#0000ff">/&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">assemblies</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">compilation</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">system.web</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">microsoft.web.services3</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">messaging</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">mtom</font> <font color="#ff0000">clientMode</font><font color="#0000ff">=&quot;On&quot;</font> <font color="#0000ff">/&gt;</font><br>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">messaging</font><font color="#0000ff">&gt;</font><br>&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">microsoft.web.services3</font><font color="#0000ff">&gt;</font><br><font color="#0000ff">&lt;/</font><font color="#800000">configuration</font><font color="#0000ff">&gt;</font></div> <p>因為有Tool可以幫忙,裡面的設定就不用一個一個打上去了.<br></p>
<p>開始步驟跟Web Service的做法一樣,開啟app.config,並做以下的設定.<br></p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0909/2009992146942.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0909/2009992146942.JPG" border="0"/></a></p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0909/2009992143817.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0909/2009992143817.JPG" border="0"/></a></p>
<p><br></p>
<p>做完上述設定,app.config就大致上完成了,接著下來就要要將Web Service加入參考,原本這是個很平常的動作,但有一點地方要注意一下,加入後的Web Service,要看一下它的Reference.cs.<br></p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0909/20099921817308.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0909/20099921817308.JPG" border="0"/></a></p>
<p>反藍的那一段必需為Microsoft.Web.Services3.WebServicesClientProtocol<br></p>
<p>系統預設會是System.Web.Services.Protocols.SoapHttpClientProtocol<br></p>
<p>這點要注意到,它會導致錯誤.<br></p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0909/2009992183455.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0909/2009992183455.JPG" border="0"/></a></p>
<p>這樣就完成大部份的設定工作,接下來就是Coding部份,在我們new Web Service時,有個屬性要記得設,RequireMtom = true;<br></p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0909/20099921222584.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0909/20099921222584.JPG" border="0"/></a></p>
<p>接下來就是呼叫Web Service的Method來進行上/下載,其實設定到這裡,已經完成了大半,而呼叫Web Service的動作就像我們在呼叫一般的function一樣,沒有什麼特別的動作,比如說下載.<br></p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0909/200999212522125.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0909/200999212522125.JPG" border="0"/></a></p>
<p>如此就可以從Web Service取得到檔案的buffer,再將buffer用FileStream寫到檔案即可,上傳也是一樣,用FileStream讀取本端的檔檔到buffer,再呼叫Web Service把這Buffer給上傳過去即可.<br></p>
<p>在使用WSE這段時間以來,發現它還不錯用,在用SSL時有遇到一點小問題,但後來也是解決了,但WSE 3.0後就沒有再出下一版了,因為它整合到WCF內,未來有機會再來看看WCF版的傳檔.<br></p>
<p>這 次程式碼的介紹部份不多,因為有點小長,主要是因為用backgroundworker,及浮動式依傳輸速率去調整Buffer的長度,如果走固定又不用 backgroundworker,程式碼就簡單許多,所以這次放上整個Source Code,給有興趣的朋友參考,這個就包含Web Service及Client端的程式.<br></p>
<p><br></p>
<p>原始碼下載 :<br></p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0909/20099921342685.rar">MTOM.rar</a></p>]]></description>
            <pubDate>Wed, 09 Sep 2009 21:36:39 +0800</pubDate>
            <guid><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2046]]></guid>
         </item>         <item>
            <title><![CDATA[MTOM檔案的續傳功能(二) Web Service]]></title>
            <link><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2045]]></link>
            <description><![CDATA[<p>　　上篇大致上說明了MTOM的相關資訊,而這篇將開始講程式實作的部份,由於這程式有Client及WS兩端的程式,所以這次將以WS端的來講,而這Client端的AP將會長的像下面的樣子,一共有四個功能,取得取單/上傳/下載,還有一個檔案驗證功能.</p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0909/200997203739524.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0909/200997203739524.JPG" alt="" border="0"/></a></p>
<p>Web.Config的設定如下:</p>
<div style="border:1px solid rgb(204, 204, 204);padding:4px;color:rgb(0, 0, 0);background-color:rgb(238, 238, 238);font-family:Verdana, 細明體;width:98%;line-height:16px;font-size:10pt;"><font color="#eeeeee">0</font><font color="#008080">1</font> <font color="#0000ff">&lt;?</font><font color="#800000">xml</font> <font color="#ff0000">version</font><font color="#0000ff">=&quot;1.0&quot;</font><font color="#0000ff">?&gt;</font><br><font color="#eeeeee">0</font><font color="#008080">2</font> <font color="#0000ff">&lt;</font><font color="#800000">configuration</font><font color="#0000ff">&gt;</font><br><font color="#eeeeee">0</font><font color="#008080">3</font>&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">configSections</font><font color="#0000ff">&gt;</font><br><font color="#eeeeee">0</font><font color="#008080">4</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">section</font> <font color="#ff0000">name</font><font color="#0000ff">=&quot;microsoft.web.services3&quot;</font> <font color="#ff0000">type</font><font color="#0000ff">=&quot;Microsoft.Web.Services3.Configuration.WebServicesConfiguration, Microsoft.Web.Services3, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35&quot;</font><font color="#0000ff">/&gt;</font><br><font color="#eeeeee">0</font><font color="#008080">5</font>&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">configSections</font><font color="#0000ff">&gt;</font><br><font color="#eeeeee">0</font><font color="#008080">6</font>&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">appSettings</font><font color="#0000ff">&gt;</font><br><font color="#eeeeee">0</font><font color="#008080">7</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">add</font> <font color="#ff0000">key</font><font color="#0000ff">=&quot;UploadPath&quot;</font> <font color="#ff0000">value</font><font color="#0000ff">=&quot;Upload&quot;</font><font color="#0000ff">/&gt;</font><br><font color="#eeeeee">0</font><font color="#008080">8</font>&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">appSettings</font><font color="#0000ff">&gt;</font><br><font color="#eeeeee">0</font><font color="#008080">9</font>&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">connectionStrings</font><font color="#0000ff">/&gt;</font><br><font color="#008080">10</font>&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">system.web</font><font color="#0000ff">&gt;</font><br><font color="#008080">11</font>&nbsp;&nbsp;&nbsp;&nbsp; <font color="#0000ff">&lt;</font><font color="#800000">compilation</font> <font color="#ff0000">debug</font><font color="#0000ff">=&quot;true&quot;</font><font color="#0000ff">&gt;</font><br><font color="#008080">12</font>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">assemblies</font><font color="#0000ff">&gt;</font><br><font color="#008080">13</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">add</font> <font color="#ff0000">assembly</font><font color="#0000ff">=&quot;Microsoft.Web.Services3, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35&quot;</font><font color="#0000ff">/&gt;</font><br><font color="#008080">14</font>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">assemblies</font><font color="#0000ff">&gt;</font><br><font color="#008080">15</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">compilation</font><font color="#0000ff">&gt;</font><br><font color="#008080">16</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">authentication</font> <font color="#ff0000">mode</font><font color="#0000ff">=&quot;Windows&quot;</font><font color="#0000ff">/&gt;</font><br><font color="#008080">17</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">webServices</font><font color="#0000ff">&gt;</font><br><font color="#008080">18</font>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">soapExtensionImporterTypes</font><font color="#0000ff">&gt;</font><br><font color="#008080">19</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">add</font> <font color="#ff0000">type</font><font color="#0000ff">=&quot;Microsoft.Web.Services3.Description.WseExtensionImporter, Microsoft.Web.Services3, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35&quot;</font><font color="#0000ff">/&gt;</font><br><font color="#008080">20</font>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">soapExtensionImporterTypes</font><font color="#0000ff">&gt;</font><br><font color="#008080">21</font>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">soapServerProtocolFactory</font> <font color="#ff0000">type</font><font color="#0000ff">=&quot;Microsoft.Web.Services3.WseProtocolFactory, Microsoft.Web.Services3, Version=3.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35&quot;</font><font color="#0000ff">/&gt;</font><br><font color="#008080">22</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">webServices</font><font color="#0000ff">&gt;</font><br><font color="#008080">23</font>&nbsp;&nbsp;&nbsp;&nbsp; <font color="#0000ff">&lt;</font><font color="#800000">httpRuntime</font> <font color="#ff0000">maxRequestLength</font><font color="#0000ff">=&quot;16384&quot;</font><font color="#0000ff">&gt;</font><font color="#0000ff">&lt;/</font><font color="#800000">httpRuntime</font><font color="#0000ff">&gt;</font><br><font color="#008080">24</font>&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">system.web</font><font color="#0000ff">&gt;</font><br><font color="#008080">25</font>&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">microsoft.web.services3</font><font color="#0000ff">&gt;</font><br><font color="#008080">26</font>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">messaging</font><font color="#0000ff">&gt;</font><br><font color="#008080">27</font>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">&lt;</font><font color="#800000">mtom</font> <font color="#ff0000">serverMode</font><font color="#0000ff">=&quot;always&quot;</font><font color="#0000ff">/&gt;</font><br><font color="#008080">28</font>&nbsp;&nbsp;&nbsp;&nbsp; <font color="#0000ff">&lt;/</font><font color="#800000">messaging</font><font color="#0000ff">&gt;</font><br><font color="#008080">29</font>&nbsp;&nbsp;<font color="#0000ff">&lt;/</font><font color="#800000">microsoft.web.services3</font><font color="#0000ff">&gt;</font><br><font color="#008080">30</font> <font color="#0000ff">&lt;/</font><font color="#800000">configuration</font><font color="#0000ff">&gt;</font><br><font color="#008080">31</font></div><p>從這個config裡可以看到幾行不是WSE就是MTOM,這些值要怎麼來?我們可以用WSE的Configuration Tool來設定,程式剛開啟時像下面一樣是空白的.</p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0909/200997205134160.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0909/200997205134160.JPG" alt="" border="0"/></a></p>
<p>這時從File -&gt; Open,開啟web.config這個檔案,就可以開始設定的動作(Client端的設定也會用到此工具,但設定不太相同),以下的設定就以畫面的方式直接顯示.</p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0909/200997205351472.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0909/200997205351472.JPG" alt="" border="0"/></a></p>
<p>(其它用預設值,不過有興趣的人,可以再針對每個細項設定去瞭解)</p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0909/20099720567895.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0909/20099720567895.JPG" alt="" border="0"/></a></p>
<p>設定完再把它給存檔即可,那麼Web.Config就會設好WSE MTOM的部份.</p>
<p>&nbsp;</p>
<p>接下來的Web Service的部份程式碼如下 :</p>
<div style="border:1px solid rgb(204, 204, 204);padding:4px;color:rgb(0, 0, 0);background-color:rgb(238, 238, 238);font-family:Verdana, 細明體;width:98%;line-height:16px;font-size:10pt;"><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/None.gif" alt="" align="top"/><font color="#0000ff">public</font> <font color="#0000ff">class</font> ServiceMTOM : System.Web.Services.WebService<br><img style="display:inline;" id="CodeFunction9663_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction9663_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedBlock.gif" alt="" align="top"/><span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction9663_shrink_text">...</span><span style="display:inline;" id="CodeFunction9663_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">private</font> <font color="#0000ff">string</font> UploadPath;<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">public</font> ServiceMTOM()<br><img style="display:inline;" id="CodeFunction3960_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction3960_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction3960_shrink_text">...</span><span style="display:inline;" id="CodeFunction3960_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#008000">// 檢查上傳路徑是否存在</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">string</font> uploadConfigSetting = ConfigurationManager.AppSettings[<font color="#800000">&quot;UploadPath&quot;</font>].ToString();<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">if</font> (Path.IsPathRooted(uploadConfigSetting))<br><img style="display:inline;" id="CodeFunction5502_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction5502_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction5502_shrink_text">...</span><span style="display:inline;" id="CodeFunction5502_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;UploadPath = uploadConfigSetting;<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">else</font><br><img style="display:inline;" id="CodeFunction8830_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction8830_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction8830_shrink_text">...</span><span style="display:inline;" id="CodeFunction8830_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;UploadPath = Server.MapPath(uploadConfigSetting);<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">if</font> (!Directory.Exists(UploadPath))<br><img style="display:inline;" id="CodeFunction9257_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction9257_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction9257_shrink_text">...</span><span style="display:inline;" id="CodeFunction9257_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Directory.CreateDirectory(Server.MapPath(uploadConfigSetting));<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br><img style="display:inline;" id="CodeRegion5383_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeRegion5383_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeRegion5383_shrink_text">Upload</span><span style="display:inline;" id="CodeRegion5383_expand_text"><font color="#0000ff">#region </font>Upload<br><img style="display:inline;" id="CodeRemark4531_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeRemark4531_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeRemark4531_shrink_text">/**/</span><span style="display:inline;" id="CodeRemark4531_expand_text"><font color="#808080">/// &lt;summary&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">///<font color="#008000"> 上傳檔案</font></font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;/summary&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;param name=<font color="#800000">&quot;FileName&quot;</font>&gt;<font color="#008000">檔案名稱 <font color="#0000ff">string</font></font>&lt;/param&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;param name=<font color="#800000">&quot;buffer&quot;</font>&gt;<font color="#008000">傳輸量 <font color="#0000ff">long</font></font>&lt;/param&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;param name=<font color="#800000">&quot;Offset&quot;</font>&gt;<font color="#008000">檔案起始 <font color="#0000ff">long</font></font>&lt;/param&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;[WebMethod]</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">public</font> <font color="#0000ff">void</font> AppendChunk(<font color="#0000ff">string</font> FileName, <font color="#0000ff">byte</font>[] buffer, <font color="#0000ff">long</font> Offset)<br><img style="display:inline;" id="CodeFunction9072_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction9072_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction9072_shrink_text">...</span><span style="display:inline;" id="CodeFunction9072_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">string</font> FilePath = Path.Combine(UploadPath, FileName);<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">if</font> (Offset == 0)&nbsp;&nbsp;&nbsp;&nbsp;<font color="#008000">// 如果起始為0,則產生一個新檔.</font><br><img style="display:inline;" id="CodeFunction4380_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction4380_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction4380_shrink_text">...</span><span style="display:inline;" id="CodeFunction4380_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;File.Create(FilePath).Close();<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">else</font> <font color="#0000ff">if</font> (!File.Exists(FilePath))<br><img style="display:inline;" id="CodeFunction2557_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction2557_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction2557_shrink_text">...</span><span style="display:inline;" id="CodeFunction2557_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CustomSoapException(<font color="#800000">&quot;檔案不存在&quot;</font>, String.Format(<font color="#800000">&quot;檔案 : <span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction8487_shrink_text">...</span><span style="display:inline;" id="CodeFunction8487_expand_text">{0}</span> 不存在&quot;</font>, FilePath));<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">long</font> FileSize = <font color="#0000ff">new</font> FileInfo(FilePath).Length;<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">if</font> (FileSize &lt; Offset)<br><img style="display:inline;" id="CodeFunction3134_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction3134_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction3134_shrink_text">...</span><span style="display:inline;" id="CodeFunction3134_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CustomSoapException(<font color="#800000">&quot;檔案Offset錯誤&quot;</font>, <font color="#800000">&quot;Offset大於檔案長度&quot;</font>);<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#008000">//開啟檔案寫入.</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">try</font><br><img style="display:inline;" id="CodeFunction3250_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction3250_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction3250_shrink_text">...</span><span style="display:inline;" id="CodeFunction3250_expand_text">{<br><img style="display:inline;" id="CodeUsing2759_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeUsing2759_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedBlock.gif" alt="" align="top"/><font color="#0000ff">public</font> <font color="#0000ff">class</font> ServiceMTOM : System.Web.Services.WebService<br><img style="display:inline;" id="CodeFunction4744_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction4744_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/><span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction4744_shrink_text">...</span><span style="display:inline;" id="CodeFunction4744_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">private</font> <font color="#0000ff">string</font> UploadPath;<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">public</font> ServiceMTOM()<br><img style="display:inline;" id="CodeFunction9350_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction9350_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction9350_shrink_text">...</span><span style="display:inline;" id="CodeFunction9350_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#008000">// 檢查上傳路徑是否存在</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">string</font> uploadConfigSetting = ConfigurationManager.AppSettings[<font color="#800000">&quot;UploadPath&quot;</font>].ToString();<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">if</font> (Path.IsPathRooted(uploadConfigSetting))<br><img style="display:inline;" id="CodeFunction2668_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction2668_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction2668_shrink_text">...</span><span style="display:inline;" id="CodeFunction2668_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;UploadPath = uploadConfigSetting;<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">else</font><br><img style="display:inline;" id="CodeFunction8360_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction8360_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction8360_shrink_text">...</span><span style="display:inline;" id="CodeFunction8360_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;UploadPath = Server.MapPath(uploadConfigSetting);<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">if</font> (!Directory.Exists(UploadPath))<br><img style="display:inline;" id="CodeFunction2876_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction2876_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction2876_shrink_text">...</span><span style="display:inline;" id="CodeFunction2876_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Directory.CreateDirectory(Server.MapPath(uploadConfigSetting));<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br><img style="display:inline;" id="CodeRegion9529_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeRegion9529_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeRegion9529_shrink_text">Upload</span><span style="display:inline;" id="CodeRegion9529_expand_text"><font color="#0000ff">#region </font>Upload<br><img style="display:inline;" id="CodeRemark7637_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeRemark7637_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeRemark7637_shrink_text">/**/</span><span style="display:inline;" id="CodeRemark7637_expand_text"><font color="#808080">/// &lt;summary&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">///<font color="#008000"> 上傳檔案</font></font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;/summary&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;param name=<font color="#800000">&quot;FileName&quot;</font>&gt;<font color="#008000">檔案名稱 <font color="#0000ff">string</font></font>&lt;/param&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;param name=<font color="#800000">&quot;buffer&quot;</font>&gt;<font color="#008000">傳輸量 <font color="#0000ff">long</font></font>&lt;/param&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;param name=<font color="#800000">&quot;Offset&quot;</font>&gt;<font color="#008000">檔案起始 <font color="#0000ff">long</font></font>&lt;/param&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;[WebMethod]</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">public</font> <font color="#0000ff">void</font> AppendChunk(<font color="#0000ff">string</font> FileName, <font color="#0000ff">byte</font>[] buffer, <font color="#0000ff">long</font> Offset)<br><img style="display:inline;" id="CodeFunction2949_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction2949_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction2949_shrink_text">...</span><span style="display:inline;" id="CodeFunction2949_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">string</font> FilePath = Path.Combine(UploadPath, FileName);<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">if</font> (Offset == 0)&nbsp;&nbsp;&nbsp;&nbsp;<font color="#008000">// 如果起始為0,則產生一個新檔.</font><br><img style="display:inline;" id="CodeFunction6099_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction6099_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction6099_shrink_text">...</span><span style="display:inline;" id="CodeFunction6099_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;File.Create(FilePath).Close();<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">else</font> <font color="#0000ff">if</font> (!File.Exists(FilePath))<br><img style="display:inline;" id="CodeFunction7134_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction7134_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction7134_shrink_text">...</span><span style="display:inline;" id="CodeFunction7134_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CustomSoapException(<font color="#800000">&quot;檔案不存在&quot;</font>, String.Format(<font color="#800000">&quot;檔案 : <span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction5148_shrink_text">...</span><span style="display:inline;" id="CodeFunction5148_expand_text">{0}</span> 不存在&quot;</font>, FilePath));<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">long</font> FileSize = <font color="#0000ff">new</font> FileInfo(FilePath).Length;<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">if</font> (FileSize &lt; Offset)<br><img style="display:inline;" id="CodeFunction1000_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction1000_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction1000_shrink_text">...</span><span style="display:inline;" id="CodeFunction1000_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CustomSoapException(<font color="#800000">&quot;檔案Offset錯誤&quot;</font>, <font color="#800000">&quot;Offset大於檔案長度&quot;</font>);<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#008000">//開啟檔案寫入.</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">try</font><br><img style="display:inline;" id="CodeFunction6128_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction6128_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction6128_shrink_text">...</span><span style="display:inline;" id="CodeFunction6128_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><font color="#0000ff">using</font> <span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeUsing2759_shrink_text">...</span><span style="display:inline;" id="CodeUsing2759_expand_text">(FileStream fs = <font color="#0000ff">new</font> FileStream(FilePath, FileMode.Open, FileAccess.ReadWrite, FileShare.Read))<br><img style="display:inline;" id="CodeFunction8860_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction8860_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction8860_shrink_text">...</span><span style="display:inline;" id="CodeFunction8860_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;fs.Seek(Offset, SeekOrigin.Begin);<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;fs.Write(buffer, 0, buffer.Length);<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">catch</font> (Exception ex)<br><img style="display:inline;" id="CodeFunction8282_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction8282_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction8282_shrink_text">...</span><span style="display:inline;" id="CodeFunction8282_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CustomSoapException(<font color="#800000">&quot;檔案寫入錯誤&quot;</font>, ex.Message);<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">#endregion</font></span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br><img style="display:inline;" id="CodeRegion2732_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeRegion2732_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeRegion2732_shrink_text">Download</span><span style="display:inline;" id="CodeRegion2732_expand_text"><font color="#0000ff">#region </font>Download<br><img style="display:inline;" id="CodeRemark9044_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeRemark9044_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeRemark9044_shrink_text">/**/</span><span style="display:inline;" id="CodeRemark9044_expand_text"><font color="#808080">/// &lt;summary&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">///<font color="#008000"> 下載檔案</font></font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;/summary&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;param name=<font color="#800000">&quot;FileName&quot;</font>&gt;<font color="#008000">檔案名稱 <font color="#0000ff">string</font></font>&lt;/param&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;param name=<font color="#800000">&quot;Offset&quot;</font>&gt;<font color="#008000">檔案起始 <font color="#0000ff">long</font></font>&lt;/param&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;param name=<font color="#800000">&quot;BufferSize&quot;</font>&gt;<font color="#008000">傳輸量 <font color="#0000ff">long</font></font>&lt;/param&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#808080">/// &lt;returns&gt;<font color="#008000">檔案 <font color="#0000ff">byte</font>[]</font>&lt;/returns&gt;</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;[WebMethod]</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">public</font> <font color="#0000ff">byte</font>[] DownloadChunk(<font color="#0000ff">string</font> FileName, <font color="#0000ff">long</font> Offset, <font color="#0000ff">int</font> BufferSize)<br><img style="display:inline;" id="CodeFunction1058_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction1058_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction1058_shrink_text">...</span><span style="display:inline;" id="CodeFunction1058_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">string</font> FilePath = Path.Combine(UploadPath, FileName);<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#008000">//檢查檔案是否存在</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">if</font> (!File.Exists(FilePath))<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CustomSoapException(<font color="#800000">&quot;檔案不存在&quot;</font>, String.Format(<font color="#800000">&quot;檔案 : <span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction4694_shrink_text">...</span><span style="display:inline;" id="CodeFunction4694_expand_text">{0}</span> 不存在&quot;</font>, FilePath));<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">long</font> FileSize = <font color="#0000ff">new</font> FileInfo(FilePath).Length;<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#008000">//如果檔案起始位置大於檔案長度</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">if</font> (Offset &gt; FileSize)<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;CustomSoapException(<font color="#800000">&quot;錯誤的下載位置&quot;</font>, String.Format(<font color="#800000">&quot;檔案大小為 <span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction5226_shrink_text">...</span><span style="display:inline;" id="CodeFunction5226_expand_text">{0}, 要求的起始位置為 {1}</span>&quot;</font>, FileSize, Offset));<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">byte</font>[] TmpBuffer;<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">int</font> BytesRead;<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">try</font><br><img style="display:inline;" id="CodeFunction2574_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction2574_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction2574_shrink_text">...</span><span style="display:inline;" id="CodeFunction2574_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#008000">//開啟檔案</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">using</font> (FileStream fs = <font color="#0000ff">new</font> FileStream(FilePath, FileMode.Open, FileAccess.Read, FileShare.Read))<br><img style="display:inline;" id="CodeFunction2972_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction2972_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction2972_shrink_text">...</span><span style="display:inline;" id="CodeFunction2972_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;fs.Seek(Offset, SeekOrigin.Begin);&nbsp;&nbsp;&nbsp;&nbsp;<font color="#008000">// 找到要求的檔案起始位置</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;TmpBuffer = <font color="#0000ff">new</font> <font color="#0000ff">byte</font>[BufferSize];<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;BytesRead = fs.Read(TmpBuffer, 0, BufferSize);&nbsp;&nbsp;&nbsp;&nbsp;<font color="#008000">// 把資料讀入buffer內</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockEnd.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</span><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">if</font> (BytesRead != BufferSize)<br><img style="display:inline;" id="CodeFunction9751_expand_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ExpandedSubBlockStart.gif" alt="" align="top"/><img style="display:none;" id="CodeFunction9751_shrink_img" src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/ContractedSubBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<span style="border:1px solid rgb(128, 128, 128);padding:0px;color:rgb(128, 128, 128);background-color:rgb(255, 255, 255);display:none;" id="CodeFunction9751_shrink_text">...</span><span style="display:inline;" id="CodeFunction9751_expand_text">{<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#008000">//最後一個檔案長度buffer可能會比BufferSize少,所以必需改變buffer的長度,以符合實際檔案長度.</font><br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/dialog/InsertCode/codeimages/InBlock.gif" alt="" align="top"/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font color="#0000ff">byte</font>[] TrimmedBuffer = <font color="#0000ff">new</font> <font color="#0000ff">byte</font>[BytesRead];<br><img src="http://www.dotblogs.com.tw/Providers/BlogEntryEditor/FCKeditor/editor/di]]></description>
            <pubDate>Mon, 07 Sep 2009 21:11:52 +0800</pubDate>
            <guid><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2045]]></guid>
         </item>         <item>
            <title><![CDATA[[續篇]一切風雲變色的開始]]></title>
            <link><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2041]]></link>
            <description><![CDATA[<p><!--{12516482526980}--><!--{12516482526981}--><style><!--{}--></style><!--{12516482526983}-->  </p>
<div>　　出國前的那些經歷,真的很珍貴,就在美國待了1年半後,滿懷著期待的心情回國,在台灣短暫的停留,畢竟已經有1年半沒有見過家人,但公司似 乎有什麼計畫在進行,所以停留沒多久就又往大陸工作,踏進熟悉的香港機場,雖然已有1年半沒來,一切都如當初踏出時所看到的景像,很習慣的到巴士站找直通 巴,上車前往工廠的方向,就在即將到廠前一刻,其實很期待見到同事,尤其是當初管理處的那群小朋友,不知道這一年半來,他們成長了多少,拖著行李踏入工 廠,雖然外觀沒什麼變,但氣氛似乎不同.</div><div><br></div>  <div>　　管理處的小朋友並沒有出現,當時只心想著,可能我回來晚了,他們先去吃飯,明天再去找他們好了,整理一下行李,很早就睡了,隔天一早起來就 開始如往昔般的去巡視廠區,順便看看工廠有那些變化,走進管理處的辨公室,眼前的景像讓我倍感吃驚,怎麼人少了那麼多?很多不錯的人材都不見了?雖然他們 有大概講了一下他們走的原因,但就我對這群小朋友的認知,這不可能會是原因,但他們似乎面有難色,我就沒有再追問下去,晚上吃飯剛好有機會問老闆他們的 事,老闆就&quot;劈頭&quot;說他們的不是,像是收黑錢,說真的,當下我還是無法相信,小朋友的反應跟老闆的答案,我覺得這兩者似乎還有我不知道的事情,但可以確定 這群小朋友已經走了大半,剩下的小朋友們,眼中似乎失去當初的光芒,而這個部門已有另一個台幹在帶領,我就不便再做干涉.</div>  <p>　　因為公司投資了一家新工廠,主要產品是電子致冷產品,常見的就是旅行用的小冰箱,插電後就能致冷或致熱,而這裡面所用的就是致冷片,早期玩電腦超頻,就有看過拿來放在CPU上降溫,只是現在拿這個東西放在冰箱上,所以對這<span>TE Chip (</span>致冷片)也有點瞭解,我就跟之前開發部的經理一起被分派到新工廠.因為這工廠是老闆跟別人合伙投資的,所以對方也派了一員代表在工廠一同管理.</p>
<div>　 　之前在電線插頭廠做過不少的職務,在這家新的工廠所擔任的職務卻是之前沒擔任過的採購,這個部門大約只有5,6人,負責採購所有的料件,說真的,這採購 還真的很難當,這間工廠才剛成立,很多人也是從插頭廠移過來,所以對這產品也不熟,很多開發案要我們去採購的東西,連工程師都不知道是什麼,需求者都不知 道的東西,採購怎麼去找?所以採購常常得像無頭蒼蠅般的瞎找,由於是新工廠,又沒有訂單,更難要到樣品,有時要個一次二次,工程人員還是說這不是他要的, 再去要第三次時,對方直接掛電話,但為了要到樣品,真的是臉放在地上任人踩.</div>  <p>　　在這情況之下,為了改善,迫使自己不得不懂&quot;工程&quot;,開始去瞭解<span>TE Chip</span>的相關資料,導熱材質,散熱 片,PU發泡,NSF的FDA要求,電源供應器,電鍍,塑料特性等,這時才能慢慢的&quot;知道&quot;他們其實需要的是什麼,所以往往帶回來的東西比他們想像中的 好,曾經帶回幾根&quot;熱導管&quot;,說明這個東西的厲害,但它也不便宜,當時很多人都沒有見過,每個人看著這細細的一根,都投著”懷疑”的眼神,也不知道要怎麼 去應用它,當下經理跳了出來,說這麼細一根有什麼用,拿了一根插在他的咖啡杯攪拌,當下所有的採購人員都傻眼,都不知道要說什麼,此時只見經理突然喊了一 聲[哦~~燙!!!!]看樣子它的導熱速度很快,但就我這樣看來,沒什麼用~由於經理負責開發部,他直接宣告沒有對這產品瞭解下去的必要,所以其他工程師 就當我們採購在”裝懂”,帶回這什麼鬼東西.</p>
<div>　　不過為了找這些散熱的東西,就比較常在外面到處跑,學一些有的沒有的東西,像是公司產品最常用的鋁擠型散熱片,所謂的鋁擠型,就有點像小朋 友的黏土玩具一樣,把黏土放在一個容器裡,這容器有一個孔,黏土在擠壓後,會從這個孔出來,所以孔是什麼樣子,出來的黏土就是什麼樣子,鋁擠型就類似這樣 的方式,一根很粗的鋁柱,在加熱後推擠通過模具,就擠出散熱片了,但此時還是一長條的,之後再拿去切割,研磨,陽極處理等,就是我們熟悉的散熱片了,這是 最快,也是最便宜的方式,但相對的也較重.</div><div><br></div>  <div>　　之前在做電線插頭之有接觸過射出成型,對其它的成型方式一無所知,後來又見了吸塑跟滾塑,吸塑成品就像是保特瓶,而滾塑呢,就像是麥當勞遊 戲區的那個塑膠溜滑梯的大型塑製品,看到製程跟模具,真的是大開眼界,那種大型的成型機真的很壯觀,感覺很像小時候去參觀小美冰淇淋工廠一樣的興奮..</div><div><br></div>  <div>　　當採購這段時間真的可以學到好多東西,誰說採購只是準時把東西買回來就好,又要便宜跟品質好,比起每天坐在電腦前設計產品的工程師,在外面東奔西跑反而看到更多.</div><div><br></div>  <div>　　雖然這個職務可以學到很多,但也很辛苦,因為公司的產品體積較大,零件庫存起來也是很可怕,所以當時所要求的是&quot;零庫存&quot;,這是一個很難達 到的目標,供應商做完就想要趕快送來,不然也是佔他們的庫存,如果送過來又會被我們退回,有時送來的零件品檢沒過,被退了回去,廠商就會很不滿,因為他們 廠區裡的&quot;庫存&quot;也同樣的打了NG,所以常常接到廠商的抱怨電話,有時對方的老總都親自來瞭解,面對這麼多的抱怨,EQ就要高了,不然搞砸了,他們不送 貨,生產線就斷線,所以曾經為了追貨,那位經理指派我去駐廠跟催,沒貨就不要回來(其實是他變規格,廠商來不及改,導致要趕貨),我從下午就出門到供應商 那,當場確認規格及品質,廠商連夜趕工的做,而我呢?原本在車子裡睡,雖然已是深夜,但依然熱到不行,加上蚊子,根本睡不著,亁脆走到外面還比較涼,看到 一張乾淨點的撞球桌(大陸很多戶外撞球)就躺了上去,看著天上的星空,心中有很多感慨,這種心情有誰能瞭解?此時眼中的光芒也漸漸淡去.隔天早上7點就把 貨帶回,生產線也沒有延誤到,整個交待完就回宿舍洗澡睡覺,上床就已經快9點了,睡到1點半就再回廠區解決問題,長時間下來,還真的很容易爆肝.</div><div><br></div>  <div>　　之前在美國學的英文都沒用到嗎?並不是,因為在美國有當地的業務,負責接洽當地廠商,再轉達客戶及工廠的訊息給彼此,所以常跟美國書信往 來,當他們來大陸時,也是跟另一名(股東)經理一起接待他們,他們來的時候也是我最累的時候,因為他們吃不慣當地的食物,所以每天都是麥當勞跟肯德雞,天 天就是那幾個套餐在那天天輪,輪完一圈再重頭來,吃到快吐了,每天陪他們到凌晨(時差好像不打算調一樣),隔天我還是7點上班,而他們是下午才出現,每當 他們來出差,我就開始期待他們快點回去.</div><div><br></div>  <div>　　雖然當採購很辛苦,但後來想來也是很開心,因為這段時間也真的學到很多,這些辛苦換來的成長,都是值得的,這段時間也有很多採購受不了這樣 的工作方式而離開了,如果我沒有成長的支持,我可能也會走上同樣的路吧,而這成長卻也是我選擇踏出去,去瞭解那些未知的知識所換來的,我想最重要的一點就 是 : 當面對問題時,正面的思考更顯重要.</div><div><br></div>  <div>　　擔任一段時間的採購後,老闆似乎不希望這間工廠是一直由另一家股東所派出來的代表在掌握業務,加上這段時間的磨練,就轉任業務,所以原本的業務就分了一些Project讓我接手,但此時的我並不知道,這些Project裡面有不少大炸彈,埋下我離開公司的引線~</div>  <div>&nbsp;</div>  <div>＊踏入下一個職位,它將會是離開時的風暴,也發現到管理處的真象</div>]]></description>
            <pubDate>Mon, 31 Aug 2009 00:10:59 +0800</pubDate>
            <guid><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2041]]></guid>
         </item>         <item>
            <title><![CDATA[UTF8轉BIG5]]></title>
            <link><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2040]]></link>
            <description><![CDATA[<p>這幾天在Trouble shooting時,有遇到一個特別的狀況,就是兩台DB的編碼設定不同,一台是設BIG5,另一台是UTF8,UTF8的資料會是查詢條件帶到BIG5 那台去,當遇到稀有字時(例如:鍈),就會有問題,這個字在BIG5顯示出來的會是&quot;?&quot;,而UTF8則是正常,那麼從UTF8帶出的&quot;鍈&quot;,要怎麼去 BIG5找出來?</p>
<p>這時找到一個方法,就是把UTF8的string轉為BIG5,這樣就能到DB去比對出來了.<br></p>
<p>Sample Code as Below.<br></p>
<p>&nbsp;&nbsp;&nbsp; public static string ConvertUTF8toBIG5(string strInput)<br>&nbsp;&nbsp;&nbsp; {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; byte[] strut8 = System.Text.Encoding.Unicode.GetBytes(strInput);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; byte[] strbig5 = System.Text.Encoding.Convert(System.Text.Encoding.Unicode, System.Text.Encoding.Default, strut8);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; return System.Text.Encoding.Default.GetString(strbig5);<br>&nbsp;&nbsp;&nbsp; }<br></p>
<p>之前寫的時候,沒想到這個問題,今天它就用&quot;鍈&quot;這個字來逞罰我,下次寫程式的時候,要注意到編碼的問題.</p>]]></description>
            <pubDate>Tue, 25 Aug 2009 22:35:53 +0800</pubDate>
            <guid><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2040]]></guid>
         </item>         <item>
            <title><![CDATA[老舊的資訊設備]]></title>
            <link><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2037]]></link>
            <description><![CDATA[<p>最近在整理家中的庫存資訊設備,每次總是想說之後可能會用到,所以就一直沒丟,就一直這樣留啊留的,現在在看到這些設備時,已經很確定它不可能會再用到了,但也沒打算丟,它們就可以算是古董了吧,也是那個世代的回憶~<br></p>
<p><br></p>
<p>現在的RAM都已經是GB級的了,但從我的庫存裡卻看到連MB及都不到的KB.<br></p>
<p>這RAM的編號是JMMS25603S,每條RAM是30PIN SIMM 80 ns,而且是日製的,當初每條可是花了我1千大洋,現在它的價值呢?55美金,還漲價了咧.<br></p>
<p>在這看到價錢 &gt;&gt; <a href="http://cfusion.com/cgi-bin/getPart_1.cgi?strSearchFragment=jmm25603s">Buy Now!</a><br></p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0908/200981423506508.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0908/200981423506508.JPG" border="0" width="300" height="225"/></a></p>
<p>這是OKI的哦~<br></p>
<p>Pin腳邊還寫著30~<br></p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0908/2009815009561.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0908/2009815009561.JPG" border="0" width="300" height="225"/></a></p>
<p>另一個老古董,這可不是什麼轉接頭,而是Pccillin的&quot;防毒鎖&quot;,看這名字及外型可能會讓人誤會說,這個可以防Print Port的毒嗎?並不是這樣的,之前的Pccillin防毒軟體要加上這個防毒鎖才能用,官方說法是在裡面有存一些東西可以救電腦(如果中毒的話),但就我看來,防盜版的意義比較大,因為那個時期是大補帖的天下,而印表機就串接在防毒鎖後,印表機的接頭已經夠長了,加上這個防毒鎖,主機後面就因為它,都會空出好大的一個空間.<br></p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0908/20098150112882.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0908/20098150112882.JPG" border="0" width="300" height="225"/></a></p>
<p>PC-cillin的Logo特寫.<br></p>
<p><a href="http://files.dotblogs.com.tw/jeff-yeh/0908/20098150141118.JPG"><img src="http://files.dotblogs.com.tw/jeff-yeh/0908/20098150141118.JPG" border="0" width="300" height="225"/></a></p>
<p><br></p>
<p>其它還有1倍速的SCSI光碟機,24/56 K Modem ,及一些顯示卡不及65535色的,後面找時間再慢慢整理吧.<br></p>]]></description>
            <pubDate>Sat, 15 Aug 2009 00:14:26 +0800</pubDate>
            <guid><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2037]]></guid>
         </item>         <item>
            <title><![CDATA[Windows各版本支援最大記憶清單]]></title>
            <link><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2036]]></link>
            <description><![CDATA[<p>最近的RAM愈來愈便宜了,但卻不知道自己的OS有沒有辨法支援到那麼大,希望以下的資訊對大家有幫助.</p>
<p>Maximum Ram supported list By Windows</p>
<p>  </p>
<table style="border-collapse:collapse;width:487pt;" border="0" cellpadding="0" cellspacing="0" width="649">       <tbody><tr style="height:16.5pt;" height="22">   <td class="xl22" style="height:16.5pt;width:353pt;" width="470" height="22">作業系統版本</td>   <td class="xl22" style="border-left:medium none;width:89pt;" width="119">32位元</td>   <td class="xl22" style="border-left:medium none;width:45pt;" width="60">64位元</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td colspan="3" class="xl22" style="height:16.5pt;" height="22">Windows Server 2008</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Server&nbsp; 2008 Datacenter (full installation)</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">64 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">2 TB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Server&nbsp; 2008 Datacenter (Server Core installation)</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">64 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">2 TB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Server&nbsp; 2008 Enterprise</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">64 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">2 TB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows Server   &nbsp;2008 HPC Edition</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">128 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows Server   &nbsp;2008 Standard</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">32 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Server&nbsp; 2008 for Itanium-Based Systems</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">2 TB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows Web   Server 2008</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">32 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td colspan="3" class="xl22" style="height:16.5pt;" height="22">Windows 7</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows Home   Basic</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">8 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Starter</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">8 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows Home   Premium</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">16 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Professional</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">192 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Enterprise &amp; Ultimate</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">192 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td colspan="3" class="xl22" style="height:16.5pt;" height="22">Windows Vista</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows&nbsp;   Vista Ultimate</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">128 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows&nbsp;   Vista Enterprise</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">128 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows&nbsp;   Vista Business</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">128 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   &nbsp;Vista Home Premium</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">16 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows&nbsp;   Vista Home Basic</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">8 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows&nbsp;   Vista Starter</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">1 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td colspan="3" class="xl22" style="height:16.5pt;" height="22">Windows Server 2003</td>  </tr>  <tr style="height:33pt;" height="44">   <td class="xl23" style="border-top:medium none;height:33pt;" height="44">Windows   Server&nbsp; 2003 with Service Pack&nbsp;2 (SP2), Datacenter Edition</td>   <td class="xl24" style="border-top:medium none;border-left:medium none;width:89pt;" width="119">128   GB<br>     64 GB with 4GT</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">2 TB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Server&nbsp; 2003 with Service Pack&nbsp;2 (SP2), Enterprise Edition</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">64 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">2 TB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Storage Server&nbsp; 2003, Enterprise Edition</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">8 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Storage Server &nbsp;2003</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:33pt;" height="44">   <td class="xl24" style="border-top:medium none;height:33pt;width:353pt;" width="470" height="44">Windows Server&nbsp; 2003 R2 Datacenter Edition<br>     Windows Server &nbsp;2003 with Service Pack&nbsp;1 (SP1), Datacenter   Edition</td>   <td class="xl24" style="border-top:medium none;border-left:medium none;width:89pt;" width="119">128   GB<br>     64 GB with 4GT</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">1 TB</td>  </tr>  <tr style="height:33pt;" height="44">   <td class="xl24" style="border-top:medium none;height:33pt;width:353pt;" width="470" height="44">Windows Server &nbsp;2003 R2 Enterprise Edition<br>     Windows Server&nbsp; 2003 with Service Pack&nbsp;1 (SP1), Enterprise   Edition</td>   <td class="xl24" style="border-top:medium none;border-left:medium none;width:89pt;" width="119">64   GB<br>     16 GB with 4GT</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">1 TB</td>  </tr>  <tr style="height:49.5pt;" height="66">   <td class="xl24" style="border-top:medium none;height:49.5pt;width:353pt;" width="470" height="66">Windows Server &nbsp;2003 R2 Standard Edition<br>     Windows Server&nbsp; 2003, Standard Edition SP1<br>     Windows Server &nbsp;2003, Standard Edition SP2</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">32 GB</td>  </tr>  <tr style="height:33pt;" height="44">   <td class="xl23" style="border-top:medium none;height:33pt;" height="44">Windows   Server&nbsp;2003, Datacenter Edition</td>   <td class="xl24" style="border-top:medium none;border-left:medium none;width:89pt;" width="119">128   GB<br>     16 GB with 4GT</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">512 GB</td>  </tr>  <tr style="height:33pt;" height="44">   <td class="xl23" style="border-top:medium none;height:33pt;" height="44">Windows   Server&nbsp;2003, Enterprise Edition</td>   <td class="xl24" style="border-top:medium none;border-left:medium none;width:89pt;" width="119">32   GB<br>     16 GB with 4GT</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">64 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Server&nbsp;2003, Standard Edition</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">16 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Server&nbsp;2003, Web Edition</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">2 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows Small   Business Server 2003</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   Compute Cluster Server&nbsp;2003</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">32 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td colspan="3" class="xl22" style="height:16.5pt;" height="22">Windows XP</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl25" style="border-top:medium none;height:16.5pt;" height="22">Windows XP   Professional</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">128 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows&nbsp;   XP Home Edition</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">128 GB</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows&nbsp;   XP Starter Edition</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">512 MB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td colspan="3" class="xl22" style="height:16.5pt;" height="22">Windows 2000</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows&nbsp;   2000 Professional</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows&nbsp;   2000 Server</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows&nbsp;   2000 Advanced Server</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">8 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows   &nbsp;2000 Datacenter Server</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">32 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td colspan="3" class="xl22" style="height:16.5pt;" height="22">Windows NT</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows NT   Workstation</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows NT   Server</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows NT   Enterprise Server</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">4 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td colspan="3" class="xl22" style="height:16.5pt;" height="22">Windows Previous   Version</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows 95</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">2 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows 98</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">2 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows ME</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">2 GB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">Windows 3.1x   Standard Edition</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">256 MB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr>  <tr style="height:16.5pt;" height="22">   <td class="xl23" style="border-top:medium none;height:16.5pt;" height="22">DOS<span style="">&nbsp;</span></td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">64 MB</td>   <td class="xl23" style="border-top:medium none;border-left:medium none;">不適用</td>  </tr> </tbody> </table> <p>&nbsp;</p>
<p>參考來源 :</p>
<p><a href="http://support.microsoft.com/default.aspx?scid=http%3A%2F%2Fsupport.microsoft.com%2Fsupport%2Fkb%2Farticles%2FQ84%2F3%2F88.ASP&amp;NoWebContent=1">Windows 3.1 Memory Limits</a><br></p>
<p><a href="http://msdn.microsoft.com/en-us/library/aa366778%28VS.85%29.aspx">Memory Limits for Windows Releases</a></p>
<p><a href="http://www.windows7update.com/Windows7versions.html">Windows 7 Versions</a><br></p>]]></description>
            <pubDate>Thu, 13 Aug 2009 20:39:19 +0800</pubDate>
            <guid><![CDATA[http://tw.myblog.yahoo.com/jeff-yeh/article?mid=2036]]></guid>
         </item>        </channel>
        </rss><!-- w2.blog.tpc.yahoo.com uncompressed/chunked Mon Nov  9 12:04:15 CST 2009 -->
