在 About.Com Delphi 裡面有一篇關於 TClientDataSet 的專欄:
A Guide to Using the TClientDataSet in Delphi applications
如果沒有買到Delphi in Depth: ClientDataSet的人,可千萬不要再錯過這篇專欄哦!
2012/11/26
2012/11/13
在Blogger裡面使用Syntax Highlight V3.0
Syntax Highlight V3.0後,Delphi, C++等語法並不能在Blogger正確被載入
Google後才找到這篇:
節錄內容如下:
這個網站很貼心的在底下寫了指令碼生成器,按照你需要的語法自動產生,之後再按上述的步驟修改Blogger範本,就可以開心使用囉!
Google後才找到這篇:
How To Add Syntax Highlighter (V3) To Blogger?
節錄內容如下:
- Select the theme of your highlighter,you can see demo of theme here.
- Then select the brushes which you want
- Click on the Get Code button
- Copy all the code from the text area
- Now go to your template
- Find for
- Add copied code just above it, tag in your template
這個網站很貼心的在底下寫了指令碼生成器,按照你需要的語法自動產生,之後再按上述的步驟修改Blogger範本,就可以開心使用囉!
基礎課程 - Delphi Interceptor Classes
利用 「Class 攔截器(Interceptor Classes)」 就可以不需要寫大量的繼承指令碼了
實戰中有時也會遇到,比方說像 TMaskEdit 的 ValidateError 事件的覆寫
實戰中有時也會遇到,比方說像 TMaskEdit 的 ValidateError 事件的覆寫
2012/11/09
2012/10/29
如何改變 TPageControl 的 Tab Title Font + BG Color
作者:吳祐賓 (2023/08/31 更新)
文章來源:tabsheet フォン変更 by www
雖然是日文的內容,可是還蠻容易理解的。
BCB6 和 Delphi 7 的 PageControl.OwnerDraw 為 True 時,但在 Win7 64bit 下會出現 Tab Title及 OnDrawTab 無功能的情況,在文末有解決方法!
以下是節錄內容:
2012/10/18
自製類 measureText 方法 - 使用 Delphi / C++ Builder
在 JavaScript 裡面有一個好用的函式:measureText
可以利用它查出 Text string 的 PX 單位寬度和高度
雖然在 Delphi 似乎不太需要用到這項功能,因為物件本身都已經有 width 和 height 屬性了
不過無聊的時候還是可以玩玩 px / width 的單位轉換
GetTextPxWidth / GetTextPxHeight 函式是參考 How to get TextWidth of string (without Canvas)?
不囉嗦了,直接來看 code 吧!
可以利用它查出 Text string 的 PX 單位寬度和高度
雖然在 Delphi 似乎不太需要用到這項功能,因為物件本身都已經有 width 和 height 屬性了
不過無聊的時候還是可以玩玩 px / width 的單位轉換
GetTextPxWidth / GetTextPxHeight 函式是參考 How to get TextWidth of string (without Canvas)?
不囉嗦了,直接來看 code 吧!
2012/10/04
FastReport 的 Variables 和 Script Variables
Variables 可在 Design 上看到變數
Script Variables 則看不到
Design script裡面使用上
是直接使用,例如:
Script Variables :
========
Delphi:
frxReport.Script.Varialbes['XXX'] := 'XYZ';
FR Design
ShowMessage(XXX); // 雖然看不到,但可以直接使用
========
Variables:
========
Delphi:
frxReport.Varialbes['XXX'] := '''XYZ''';
FR Design
ShowMessage(<XXX>
========
FastScript 若使用非 Pascal 語言來讀取變數時 (2024/05/28 更新)
若使用非 Pascal 語言時,以 JScript 為例,使用上不能採用快截符號讀取變數,會發生判斷式錯誤的例外。只能使用 Report 物件來讀取:
Report.Variables["XXX"] or Report.Script.Variables["XXX"]
參考來源:
- Script variables
- FastReport 4 Programmer's manual
- Why is Fast Report VCL in Delphi raising a stack overflow exception when editing a variable?
- Content of variable raises an exception - Expression expected
![]() |
| YA! 又過一關囉! |
訂閱:
文章 (Atom)

