2.選擇"一般" -> "資源檔" ->輸入名稱 -> "新增" (就會產生resource檔)
4.拉個簡單UI測試 (一個button 對應一個 label)
5. 前面加入 "using System.Configuration;"
使用方法 :
public static string 變數名稱 = Resource檔名稱.檔內要呼叫的變數名稱;
public static string test1 = Resource1.String_test;
呼叫變數名稱就可以從Resource檔內撈數值出來使用
在Resource檔內可以方便管理所有參數
6.測試,點選按鈕Label會改變數值,數值從Resource檔內取出

沒有留言:
張貼留言