2017年7月27日 星期四

2017年6月5日 星期一

diskpart cmd 指令

diskpart /s scriptname.txt
以上就是bat檔
至於要在 diskpart 下的指令就寫在 scriptname.txt 裡面
以上

2017年5月8日 星期一

Google EXCEL當資料庫讀取

跟工作相關並紀錄一下
又學到的新技能

HTML部分

<table>
<tr>
<th>驅動名稱</th>
<th>PN</th>
</tr>
    <tbody id="producttable">
    </tbody>
</table>

<select id="shopList2">
  <option></option>
</select>

<select size=5 multiple id="shopList">
     <option></option>
    </select>

multiple  > 讓下拉式選單變成多選


JAVASCRIPT部分


<script src="/jquery/jquery-1.11.1.min.js">
</script>

<script>
var Name = ["commonuse", "nfl10", "nfl11", "bk10hb11", "msl11", "lrw10", "lrw11"];
var myselect2=document.getElementById("shopList2")
 for (var j=0; j < 7; j++){
           myselect2.add(new Option(Name[j], Name[j]), myselect2.options[0])
        }
</script>

<script>

$(function(){
    var ProductName = [];
    var Price = [];
    var myselect=document.getElementById("shopList")
    $.getJSON('https://spreadsheets.google.com/feeds/list/11yf-2-AbHuG4bOf2ZC0tYxYwp8l1hbXQ3JKaVesqX1U/2/public/values?alt=json', function (data){
        for (var i=0; i < data.feed.entry.length; i++){
            ProductName[i] = data.feed.entry[i].gsx$nfl10.$t;
            Price[i] = data.feed.entry[i].gsx$pn.$t;
            $('#producttable').append("<tr><td>" + ProductName[i] + "</td><td>" + Price[i] + "</td></tr>");
            myselect.add(new Option(ProductName[i], ProductName[i]), myselect.options[0])
        }
    });
});

</script>

$('#producttable').append > table

myselect.add > 動態下拉式選單

myselect.add(new Option("選項名", ""), myselect.options[第幾個選項])


表單轉JSON
https://spreadsheets.google.com/feeds/list/文件ID/第幾個工作表/public/values?alt=json



用法來源 : 

1. 表單轉JSON : https://goo.gl/h4oskR + https://goo.gl/zw9jLb + 自己研究
2. SELECT : https://goo.gl/uqM6lS

2017年5月4日 星期四

google試算表資料庫

google試算表資料庫
一個有點燒腦的東西
但弄懂後就很好用
畢竟是個免費的公開資源
教學網址 :
http://ithelp.ithome.com.tw/articles/10188323?sc=iThomeR

2017年4月7日 星期五

NAS

預計買個NAS來玩玩
QNAP TS-228
Synology DS216PLAY
最後QNAP勝出  > 3500而已
之後有閒錢在買多bay數來玩玩 XD

2017年3月29日 星期三

開啟TEST MODE

如標題

OTM.cmd
@echo off
diskpart /s diskpart_script_otm.txt
cd \EFI\Microsoft\Boot
bcdedit /store .\BCD /set {default} testsigning on

diskpart_script_otm.txt
sel vol c
sel part 1
list part
assign letter=s
exit

P.S: diskpart 由於算特殊指令  需要將 diskpart 裡面想下的指令打好成文字檔
     再去使用 diskpart /s  呼叫

2017年3月22日 星期三

好用的修復usb

推個網站給下載
可拿來做開機修復的USB
以下
https://goo.gl/rqdsAq


另外
原本是要來修記憶卡的
但直接宣告死亡..

dism 指令

Dism /Get-imageInfo /imagefile:E:\sources\install.wim
Dism /apply-image /imagefile:E:\install.swm /swmfile:E:\install*.swm /index:1 /applydir:C:\
整天搞這兩指令就飽了
好難弄.....
參考用法來源 : http://durphy.lofter.com/post/3b5fac_747749e

2017年3月13日 星期一

好用的 cmd 指令 (01)

最近在工作上有接觸 cmd 指令
這邊記一下好用的東西
========================================================
if + findstr using
========================================================
findstr "string" file
if errorlevel 1 (
    echo String NOT found...
) else (
    echo String found
)
========================================================
Example for findstr
========================================================
F:\test>findstr /v "black white" blackwhite.txt

red
blue

========================================================
F:\test>findstr "black white" blackwhite.txt

black
white
black white
black and white

========================================================
F:\test>findstr /c:"black white" blackwhite.txt

black white

========================================================
F:\test>findstr "white" blackwhite.txt | findstr "black"

black white
black and white

========================================================
findstr + errorlevel code
========================================================
findstr /C:FFFF info_1.hex
IF ERRORLEVEL 1 goto NOT_MATCH
echo MATCH
goto END

2017年3月12日 星期日

2017.03 近況

是說

剛剛看了一下
距離我上一次發文使用這個
已經大概是4年前了吧XD
而且那個時候還算是一個滿腔熱血的高中還是大學生
想到就來使用看看的狀況
到現在已經是每天等放假的上班族
時間真的過得很快...
之後應該會在這跟巴哈小屋更新有關小說的計畫
算是重新啟動吧
大概就是這樣啦~