之前有寫一篇「In wxMEdit(MadEdit)Searching for line breaks」,Just happened to encounter the same need today,Now I've actually switched from wxMEdit to MadEdit-Mod,Basically the same,就用文章提到的「正規運算式」來搜尋 \n 並取代。奇怪的是搜尋到了,也取代了,但結果換行符號還是存在,且再搜尋一次 \n 就找不到了。
繼續瀏覽 »
Using Telegram on Manjaro has always had the problem of being unable to input Chinese via gcin,Tried a few methods found online,like setting the QT_IM_MODULE path,although it was possible to switch to 'Ciyin',it still came out in English,some people say this method only works for the official version,but I tried it and still failed,in the end, I had no choice but to follow Line's approach,using Chrome to simulate an App。
繼續瀏覽 »
When using Quick Report 1920*1080 with resolution plus 125% and higher display settings,the 'Preview Print' scale may be incorrect(either too large or too small),but the actual printout is normal,To fix this,you need to modify the qrprntr.pas file of Quick Report in the development environment,There are two ways to fix this。

我的電腦固定有外接一顆 NTFS 的硬碟,最近開機後,在 Thunar 點擊這顆硬碟,都會掛載失敗,錯誤訊息時 “error mounting wrong fs type bad option bad superblock…”。
【VLAN Setup】
◎ 'VLAN' → '802.1Q' → 'Advanced' → 'VLAN Configuration',Select 'Enable'。
◎ Add VLAN IDs one by one,For example:53、172。

During program installation,The message 'No more space left on device' appears,Check with df -h,It means /tmp is full。
我的 /tmp 非獨立磁區,是跟 / 同磁區,且 / 還有空間,所以可以透過重新 mount 的指令來暫時增加 /tmp 的空間。
df -h /tmp #查詢 /tmp 佔用空間。 sudo mount -o remount,size=15G /tmp/ #將 /tmp 大小改成 15G。 df -h /tmp #確認 /tmp 的佔用 % 是否改變。
若要清空 /tmp,可以執行以下指令:
sudo rm -r /tmp/*
【參考連結】
在安裝網路印表機時,有時會在點兩下後,出現 0x00000BCB 的錯誤,通常發生在條碼標籤機以及點陣印表機,大型事務機則沒發生過,通常重新安裝 Windows Server 上的驅動可以解決,但是隔一段時間後,就又會發生。
繼續瀏覽 »
<%# Eval("SDate", "{0:yyyy/MM/dd}") %>
// 0: 表示定義整個括號裡面的第 0 個變數要採用此日期格式。
// 以下為兩個變數的範例。
string s = String.Format("At {0}, the temperature is {1}°C.",
DateTime.Now, 20.4);
Console.WriteLine(s);
// Output similar to: 'At 4/10/2015 9:29:41 AM, the temperature is 20.4°C.'
【參考連結】
- asp.net – how to apply particular FORMAT of date by using eval? – Stack Overflow
- c# – What does the 0 in “{0:MM dd yyyy}” do? – Stack Overflow
- String.Format 方法 (System) | Microsoft Docs
- 自訂日期與時間格式字串 | Microsoft Docs
- 標準日期和時間格式字串 | Microsoft Docs
| 設定頁面 | 對象 | 設定值位置 |
| 「捷徑」 | 該捷徑 | Shortcut File |
| Compatibility | This User | Key(Note 1.) |
| Compatibility for All Users | All Users | Key(Note 2.) |
Note 1.
電腦\HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers
Note 2.
電腦\HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\AppCompatFlags\Layers
PS. 機碼為「字串值」,值為”~ RUNASADMIN”。
unit unit1;
interface
uses
Windows, Messages....
type
TFormName = (Casefm1, Casefm2, Casefm3);
function xxx(): Boolean;
var
StrFormName: String;
CaseFormName: TFormName;
begin
StrFormName := 'Case' + vFormName;
// 將 FormName(物件) 與 TFormName(值) 做區隔。
// (vFormName為帶有各FormName的字串變數)
CaseFormName := TFormName(GetEnumValue(TypeInfo(TFormName), StrFormName));
case CaseFormName of
Casefm1:
begin
..............
end;
Casefm2:
begin
..............
end;
Casefm3:
begin
...............
end;
【參考連結】
- case 判斷string的方法 | 三窟







